From 3e043fb1a553389551481ecccd67651b1b89e22c Mon Sep 17 00:00:00 2001 From: Sergei Reznikov Date: Sat, 30 Jul 2022 23:58:17 +0300 Subject: [PATCH] rpcsvc_proto: add recipe --- .../patches/rpcsvc_proto-1.4.3.patchset | 33 ++++++++++ .../rpcsvc-proto/rpcsvc_proto-1.4.3.recipe | 60 +++++++++++++++++++ 2 files changed, 93 insertions(+) create mode 100644 net-libs/rpcsvc-proto/patches/rpcsvc_proto-1.4.3.patchset create mode 100644 net-libs/rpcsvc-proto/rpcsvc_proto-1.4.3.recipe diff --git a/net-libs/rpcsvc-proto/patches/rpcsvc_proto-1.4.3.patchset b/net-libs/rpcsvc-proto/patches/rpcsvc_proto-1.4.3.patchset new file mode 100644 index 000000000..582dc91ff --- /dev/null +++ b/net-libs/rpcsvc-proto/patches/rpcsvc_proto-1.4.3.patchset @@ -0,0 +1,33 @@ +From 32e83f3beeeaecce31c40a2ac6893c6b97f7136a Mon Sep 17 00:00:00 2001 +From: Sergei Reznikov +Date: Sat, 30 Jul 2022 15:45:44 +0300 +Subject: Haiku fixes + + +diff --git a/rpcgen/rpc_main.c b/rpcgen/rpc_main.c +index 277adc6..c8de108 100644 +--- a/rpcgen/rpc_main.c ++++ b/rpcgen/rpc_main.c +@@ -68,6 +68,10 @@ + # endif + #endif + ++#ifdef __HAIKU__ ++# define stat64 stat ++#endif ++ + struct commandline + { + int cflag; /* xdr C routines */ +@@ -970,7 +974,7 @@ mkfile_output (struct commandline *cmd) + temp = rindex (cmd->infile, '.'); + cp = stpcpy (mkfilename, "Makefile."); + if (temp != NULL) +- *((char *) stpncpy (cp, cmd->infile, temp - cmd->infile)) = '\0'; ++ *((char *) strncpy (cp, cmd->infile, temp - cmd->infile)) = '\0'; + else + stpcpy (cp, cmd->infile); + +-- +2.36.1 + diff --git a/net-libs/rpcsvc-proto/rpcsvc_proto-1.4.3.recipe b/net-libs/rpcsvc-proto/rpcsvc_proto-1.4.3.recipe new file mode 100644 index 000000000..5d5e036a9 --- /dev/null +++ b/net-libs/rpcsvc-proto/rpcsvc_proto-1.4.3.recipe @@ -0,0 +1,60 @@ +SUMMARY="Protocol definitions from glibc" +DESCRIPTION="This package contains rpcsvc proto.x files from glibc, which are \ +missing in libtirpc. Additionaly, it contains rpcgen, which is needed to create \ +header files and sources from protocol files." +HOMEPAGE="https://github.com/thkukuk/rpcsvc-proto" +COPYRIGHT="2022 Thorsten Kukuk" +LICENSE="GNU LGPL v2" +REVISION="1" +SOURCE_URI="https://github.com/thkukuk/rpcsvc-proto/archive/refs/tags/v$portVersion.tar.gz" +CHECKSUM_SHA256="6906e0f81bb016bd0216460fc879d3d9f2f6d743be7dfb0d8b32d140226d5ef8" +SOURCE_DIR="rpcsvc-proto-$portVersion" +PATCHES="rpcsvc_proto-$portVersion.patchset" + +ARCHITECTURES="all" +SECONDARY_ARCHITECTURES="x86_gcc2 x86" + +PROVIDES=" + rpcsvc_proto$secondaryArchSuffix= $portVersion + cmd:rpcgen$secondaryArchSuffix = $portVersion + " +REQUIRES=" + haiku + lib:libintl$secondaryArchSuffix + " + +PROVIDES_devel=" + rpcsvc_proto${secondaryArchSuffix}_devel = $portVersion + devel:rpcsvc_proto = $portVersion + " +REQUIRES_devel=" + rpcsvc_proto == $portVersion base + " + +BUILD_REQUIRES=" + haiku${secondaryArchSuffix}_devel + " +BUILD_PREREQUIRES=" + cmd:aclocal + cmd:automake + cmd:autopoint + cmd:autoreconf + cmd:find + cmd:gcc$secondaryArchSuffix + cmd:make + " + +BUILD() +{ + ./autogen.sh + runConfigure configure + make $jobArgs +} + +INSTALL() +{ + make install + + packageEntries devel \ + $developDir +}