Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 393610 Details for
Bug 530080
net-libs/libtirpc-0.2.5: patchset to allow building against musl libc
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
patch against hardened musl branch
0001-add-musl-based-libtirpc.patch (text/plain), 73.68 KB, created by
DaggyStyle
on 2015-01-10 14:47:30 UTC
(
hide
)
Description:
patch against hardened musl branch
Filename:
MIME Type:
Creator:
DaggyStyle
Created:
2015-01-10 14:47:30 UTC
Size:
73.68 KB
patch
obsolete
>From b941cbea59240bd0e8fb828c614733145bb3a4b7 Mon Sep 17 00:00:00 2001 >From: Dagg <daggs@gmx.com> >Date: Sat, 10 Jan 2015 14:46:39 +0000 >Subject: [PATCH] add musl based libtirpc > >--- > net-libs/libtirpc/ChangeLog | 187 +++ > net-libs/libtirpc/Manifest | 15 + > ...rpcbynumber-and-getrpcbyname-if-those-are.patch | 85 ++ > .../libtirpc/files/0002-Misc-header-fixes.patch | 40 + > .../libtirpc/files/0003-fix_cdefs_h_include.patch | 618 ++++++++++ > net-libs/libtirpc/files/0004-fix_DECLS.patch | 1226 ++++++++++++++++++++ > .../libtirpc/files/0005-fix_remaining_issues.patch | 14 + > .../libtirpc/files/0006-fix_queue_h_include.patch | 44 + > net-libs/libtirpc/files/0007-no-des.patch | 29 + > .../libtirpc/files/libtirpc-0.2.1-fortify.patch | 18 + > .../files/libtirpc-0.2.2-rpc-des-prot.patch | 36 + > .../libtirpc/files/libtirpc-0.2.5-stdarg.patch | 29 + > net-libs/libtirpc/libtirpc-0.2.5-r99.ebuild | 74 ++ > net-libs/libtirpc/metadata.xml | 5 + > 14 files changed, 2420 insertions(+) > create mode 100644 net-libs/libtirpc/ChangeLog > create mode 100644 net-libs/libtirpc/Manifest > create mode 100644 net-libs/libtirpc/files/0001-Provide-getrpcbynumber-and-getrpcbyname-if-those-are.patch > create mode 100644 net-libs/libtirpc/files/0002-Misc-header-fixes.patch > create mode 100644 net-libs/libtirpc/files/0003-fix_cdefs_h_include.patch > create mode 100644 net-libs/libtirpc/files/0004-fix_DECLS.patch > create mode 100644 net-libs/libtirpc/files/0005-fix_remaining_issues.patch > create mode 100644 net-libs/libtirpc/files/0006-fix_queue_h_include.patch > create mode 100644 net-libs/libtirpc/files/0007-no-des.patch > create mode 100644 net-libs/libtirpc/files/libtirpc-0.2.1-fortify.patch > create mode 100644 net-libs/libtirpc/files/libtirpc-0.2.2-rpc-des-prot.patch > create mode 100644 net-libs/libtirpc/files/libtirpc-0.2.5-stdarg.patch > create mode 100644 net-libs/libtirpc/libtirpc-0.2.5-r99.ebuild > create mode 100644 net-libs/libtirpc/metadata.xml > >diff --git a/net-libs/libtirpc/ChangeLog b/net-libs/libtirpc/ChangeLog >new file mode 100644 >index 0000000..147c6e2 >--- /dev/null >+++ b/net-libs/libtirpc/ChangeLog >@@ -0,0 +1,187 @@ >+# ChangeLog for net-libs/libtirpc >+# Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2 >+# $Header: /var/cvsroot/gentoo-x86/net-libs/libtirpc/ChangeLog,v 1.44 2014/12/30 18:09:41 maekke Exp $ >+ >+ 30 Dec 2014; Markus Meier <maekke@gentoo.org> libtirpc-0.2.5.ebuild: >+ arm stable, bug #525268 >+ >+ 09 Dec 2014; Jeroen Roovers <jer@gentoo.org> libtirpc-0.2.5.ebuild: >+ Stable for HPPA (bug #525268). >+ >+ 12 Aug 2014; Mike Frysinger <vapier@gentoo.org> >+ +files/libtirpc-0.2.5-stdarg.patch, libtirpc-0.2.5.ebuild: >+ Add missing include of stdarg.h. >+ >+ 11 Aug 2014; Mike Frysinger <vapier@gentoo.org> libtirpc-0.2.4-r1.ebuild: >+ Mark arm64/ppc/ppc64/s390/sh stable #514912. >+ >+*libtirpc-0.2.5 (09 Aug 2014) >+ >+ 09 Aug 2014; Mike Frysinger <vapier@gentoo.org> +libtirpc-0.2.5.ebuild: >+ Version bump. >+ >+ 01 Aug 2014; Raúl Porcel <armin76@gentoo.org> libtirpc-0.2.4-r1.ebuild: >+ ia64/sparc stable wrt #514912 >+ >+ 18 Jul 2014; Tobias Klausmann <klausman@gentoo.org> libtirpc-0.2.4-r1.ebuild: >+ Stable on alpha, bug #514912 >+ >+ 28 Jun 2014; Sergey Popov <pinkbyte@gentoo.org> libtirpc-0.2.4-r1.ebuild: >+ amd64/arm/x86 stable, wrt bug #514912 >+ >+ 25 Jun 2014; Jeroen Roovers <jer@gentoo.org> libtirpc-0.2.4-r1.ebuild: >+ Stable for HPPA (bug #514912). >+ >+ 18 Jun 2014; MichaŠGórny <mgorny@gentoo.org> libtirpc-0.2.4-r2.ebuild: >+ Update dependencies to require guaranteed EAPI=5 or multilib ebuilds, bug >+ #513718. >+ >+*libtirpc-0.2.4-r2 (30 May 2014) >+ >+ 30 May 2014; MichaŠGórny <mgorny@gentoo.org> +libtirpc-0.2.4-r2.ebuild: >+ Enable multilib support. >+ >+*libtirpc-0.2.4-r1 (02 Feb 2014) >+ >+ 02 Feb 2014; Mike Frysinger <vapier@gentoo.org> +libtirpc-0.2.4-r1.ebuild: >+ Depend on virtual/krb5 for USE=kerberos rather than gssglue #493912 by Torsten >+ Kaiser. >+ >+ 18 Jan 2014; Mike Frysinger <vapier@gentoo.org> libtirpc-0.2.2-r1.ebuild, >+ libtirpc-0.2.3.ebuild, libtirpc-0.2.4.ebuild: >+ Add arm64 love. >+ >+*libtirpc-0.2.4 (10 Dec 2013) >+ >+ 10 Dec 2013; Mike Frysinger <vapier@gentoo.org> +libtirpc-0.2.4.ebuild: >+ Version bump. >+ >+*libtirpc-0.2.3 (18 Feb 2013) >+ >+ 18 Feb 2013; Mike Frysinger <vapier@gentoo.org> +libtirpc-0.2.3.ebuild: >+ Version bump. >+ >+ 09 Jul 2012; Diego E. Pettenò <flameeyes@gentoo.org> -libtirpc-0.2.2.ebuild: >+ Remove masked version. >+ >+ 05 May 2012; Jeff Horelick <jdhore@gentoo.org> libtirpc-0.2.1-r1.ebuild, >+ libtirpc-0.2.2.ebuild, libtirpc-0.2.2-r1.ebuild: >+ dev-util/pkgconfig -> virtual/pkgconfig >+ >+ 02 Mar 2012; Brent Baude <ranger@gentoo.org> libtirpc-0.2.2-r1.ebuild: >+ Marking libtirpc-0.2.2-r1 ppc64 for bug 394979 >+ >+ 15 Feb 2012; Brent Baude <ranger@gentoo.org> libtirpc-0.2.2-r1.ebuild: >+ Marking libtirpc-0.2.2-r1 ppc for bug 394979 >+ >+ 15 Jan 2012; Raúl Porcel <armin76@gentoo.org> libtirpc-0.2.2-r1.ebuild: >+ alpha/ia64/s390/sh/sparc stable wrt #394979 >+ >+ 04 Jan 2012; Pawel Hajdan jr <phajdan.jr@gentoo.org> >+ libtirpc-0.2.2-r1.ebuild: >+ x86 stable wrt bug #394979 >+ >+ 22 Dec 2011; Markus Meier <maekke@gentoo.org> libtirpc-0.2.2-r1.ebuild: >+ arm stable, bug #394979 >+ >+ 20 Dec 2011; Jeroen Roovers <jer@gentoo.org> libtirpc-0.2.2-r1.ebuild: >+ Stable for HPPA (bug #394979). >+ >+ 16 Dec 2011; Agostino Sarubbo <ago@gentoo.org> libtirpc-0.2.2-r1.ebuild: >+ Stable for AMD64, wrt bug #394979 >+ >+*libtirpc-0.2.2-r1 (11 Jun 2011) >+ >+ 11 Jun 2011; Mike Frysinger <vapier@gentoo.org> +libtirpc-0.2.2-r1.ebuild, >+ +files/libtirpc-0.2.2-rpc-des-prot.patch: >+ Stub out des_crypt for now #370713 by Nicolas Schlumberger, fix building with >+ glibc-2.14 #370663 by Diego Elio Pettenò, restore static lib support, and >+ start installing into / for glibc replacement. >+ >+*libtirpc-0.2.2 (07 Jun 2011) >+ >+ 07 Jun 2011; Diego E. Pettenò <flameeyes@gentoo.org> +libtirpc-0.2.2.ebuild: >+ Version bump, which should hopefully build with glibc-2.14. >+ >+ 20 Jan 2011; Kacper Kowalik <xarthisius@gentoo.org> >+ libtirpc-0.2.1-r1.ebuild: >+ ppc64 stable wrt #340189 >+ >+ 13 Nov 2010; Raúl Porcel <armin76@gentoo.org> libtirpc-0.2.1-r1.ebuild: >+ alpha/ia64/s390/sh/sparc stable wrt #340189 >+ >+ 26 Oct 2010; Jeroen Roovers <jer@gentoo.org> libtirpc-0.2.1-r1.ebuild: >+ Stable for HPPA (bug #340189). >+ >+ 16 Oct 2010; Markus Meier <maekke@gentoo.org> libtirpc-0.2.1-r1.ebuild: >+ arm stable, bug #340189 >+ >+ 15 Oct 2010; Brent Baude <ranger@gentoo.org> libtirpc-0.2.1-r1.ebuild: >+ stable ppc, bug 340189 >+ >+ 10 Oct 2010; Pawel Hajdan jr <phajdan.jr@gentoo.org> >+ libtirpc-0.2.1-r1.ebuild: >+ x86 stable wrt bug #340189 >+ >+ 10 Oct 2010; Markos Chandras <hwoarang@gentoo.org> >+ libtirpc-0.2.1-r1.ebuild: >+ Stable on amd64 wrt bug #340189 >+ >+ 12 Sep 2010; Diego E. Pettenò <flameeyes@gentoo.org> >+ files/libtirpc-0.2.1-fortify.patch: >+ Use an even better patch to avoid overflow on the other senses if >+ hp_length is less than four. >+ >+*libtirpc-0.2.1-r1 (12 Sep 2010) >+ >+ 12 Sep 2010; Diego E. Pettenò <flameeyes@gentoo.org> >+ -libtirpc-0.2.0.ebuild, -files/libtirpc-0.2.0-hppa-float.patch, >+ -files/libtirpc-0.2.0-no-gss.patch, -libtirpc-0.2.1.ebuild, >+ +libtirpc-0.2.1-r1.ebuild, +files/libtirpc-0.2.1-fortify.patch: >+ Add patch to fix a possible overflow (reported by _FORTIFY_SOURCE=2); >+ thanks to Joshua Kinard (Kumba) for reporting. Cleanup old versions and >+ patches. >+ >+*libtirpc-0.2.1 (23 Jul 2010) >+ >+ 23 Jul 2010; Diego E. Pettenò <flameeyes@gentoo.org> >+ +libtirpc-0.2.1.ebuild: >+ Version bump, disable static libraries (it needs gssapi that uses libdl >+ anyway), remove .la file (helps fixing bug #293593), move to EAPI=2 while >+ at it. >+ >+ 30 May 2009; Mike Frysinger <vapier@gentoo.org> libtirpc-0.2.0.ebuild, >+ +files/libtirpc-0.2.0-hppa-float.patch: >+ Fix build failure on hppa and add keywords for all. >+ >+ 30 May 2009; Mike Frysinger <vapier@gentoo.org> libtirpc-0.2.0.ebuild: >+ Restore /etc/netconfig file. >+ >+ 30 May 2009; Mike Frysinger <vapier@gentoo.org> libtirpc-0.2.0.ebuild, >+ +files/libtirpc-0.2.0-no-gss.patch: >+ Fix link error when USE=-gss. >+ >+*libtirpc-0.2.0 (30 May 2009) >+ >+ 30 May 2009; Mike Frysinger <vapier@gentoo.org> +libtirpc-0.2.0.ebuild: >+ Version bump. >+ >+ 01 Feb 2009; Markus Meier <maekke@gentoo.org> libtirpc-0.1.10.ebuild: >+ amd64/x86 stable, bug #256691 >+ >+*libtirpc-0.1.10 (28 Nov 2008) >+ >+ 28 Nov 2008; Mike Frysinger <vapier@gentoo.org> +libtirpc-0.1.10.ebuild: >+ Version bump #249151 by Chi-Thanh Christopher Nguyen. >+ >+*libtirpc-0.1.7-r1 (11 May 2008) >+ >+ 11 May 2008; Mike Frysinger <vapier@gentoo.org> >+ +files/libtirpc-0.1.7-CVE-2007-3999.patch, +libtirpc-0.1.7-r1.ebuild: >+ Add fix for CVE-2007-3999 #214208 by Robert Buchholz. >+ >+*libtirpc-0.1.7 (29 Dec 2007) >+ >+ 29 Dec 2007; Mike Frysinger <vapier@gentoo.org> +metadata.xml, >+ +libtirpc-0.1.7.ebuild: >+ Initial ebuild by me. >diff --git a/net-libs/libtirpc/Manifest b/net-libs/libtirpc/Manifest >new file mode 100644 >index 0000000..0ff5d65 >--- /dev/null >+++ b/net-libs/libtirpc/Manifest >@@ -0,0 +1,15 @@ >+AUX 0001-Provide-getrpcbynumber-and-getrpcbyname-if-those-are.patch 2012 SHA256 9ff042aa7ba870d2d581f2815eee9cae7620df6b3a725da4c4d555325a08a05d SHA512 e60fc98c9efaa4675d08e85b669d8dea07b2c7e7b268344e06e172f5751baf6fae7f354149d738f4bbe139ff5b964f1d80d0bfa91a1c9ca94f9ab9489618166d WHIRLPOOL b0977e6af76929f9279b253ecb30c7b265da130bb76ea87ab5709372bb74f02b3a7c508394b72be785c7396cc171ec2da98857b1b49dcca3a3f6324d8f2c7b28 >+AUX 0002-Misc-header-fixes.patch 1074 SHA256 519dd9015db2505404118e0067c7cbfec22b0df1371691c52568290f4a6641eb SHA512 aa5c158fb2c8f28b046831d383edc78421f71f4f632d1880e4beb30c9dfb1ea8814889c1256a82fccde06d1cfe7840ed23e857900a38bc738bf31d79c7a1ef75 WHIRLPOOL 334e566fd89f40134f46f2c852f15cf6d2062f6bec9d5fb6773b81a4abc45096acbc4577543f9a73b68578678fda6be2a5b512f90e031524126cde75040a6b7d >+AUX 0003-fix_cdefs_h_include.patch 15313 SHA256 c5bae800d887a08eba89d817b6cc19c4337b14e53f2ce8e9fb7e9984dbfe4168 SHA512 cf686acda95f8ccca486b518ee2ada42a443b3cc524bf4374b770612f501e0f2a75c61c8586a9d490ce3ee1e373559cf72c380d9fa99a75d0037b74e35fa3647 WHIRLPOOL 12915a1d45649695198c20bd609681f640bdbf3a1b40554d051e6a07534b7889a4676990edab90605571f0bc2caaebae074f3c6ec9ef88304c597acd0580b7a8 >+AUX 0004-fix_DECLS.patch 29124 SHA256 bdc844c56cfe2d5b060d59fee009576895504e2df492423ddaedd9915c785650 SHA512 8d0efe87a0e8444dd10d4b63430dfd038a7591a0a1e54bc539a4023c7421a89caae1c811d6a2ed4e33fd4d0beebd48c11fc28b5de41dbedf0c1e0fbeb8885cf3 WHIRLPOOL 5ec477f9dfb79a53b2689dea6e158c42437f0c15e18f0eebd3aede63e59b1191974fd913b26db352feb84d468dd7770e102510022ae2b017aa634f0e9e335a27 >+AUX 0005-fix_remaining_issues.patch 373 SHA256 db061da4e22c4ed9192587a622454e69c6999b5ccfdafa5588957440051277e2 SHA512 db70a64424904a669534e25c70b13dffb0ddd3437e81f6fee69ac2399e00bdd4e83ee9c65bc0bb789e28c1ac8e030a22461642e699fd371a4f147782a5845912 WHIRLPOOL 06e9f643c66867ddf965427e5c874eaa3c4275b961634d3fc669120275e3db8613a9bd997d612976c078584e016234f34e5a4abfeef20eb655997c7825e8cb56 >+AUX 0006-fix_queue_h_include.patch 1788 SHA256 3b8f296eb375052210874ebc3caeadd0cdf689a27e279761e16d76b411e89f8f SHA512 f5a419d883dc6fc0bc6ebb02c3b1f7ce95aeb2b261eb5a49498b600844a27041b32f146fd8bba3d1769c32a67a15b9e40d9ffe3598d9448ebfc4fde6446e69aa WHIRLPOOL 1e7b71255a11abd45dc88b74d8d8146f60c0a621ebe42f437e45e01f791a0ca020c27f841091f556d33fd284336b2e8cc8fa91fa9ca9ed5dd5904c1a5fe82212 >+AUX 0007-no-des.patch 960 SHA256 12823f030b803045108df782018d04ca253d4439b0e92015ddb140dcd33c1be3 SHA512 95ad086657d008a01a4072ba7141391cbbe8ac35372b2f063a3f9774eb5dfa12b97bcff0c1b6da2d887001beaa60a8524823df93a8de2fdb73ad2a30340770ba WHIRLPOOL bd075834fddeff5ae86b90273f5c7b820f88649045e65b63d09dc26c35ada0fd1162dcf8aeb1cd82ad59b9092eceb92e154fa58c9beca540dc31ead7cc96b72e >+AUX libtirpc-0.2.1-fortify.patch 704 SHA256 e3436a6de8182e51c577000917feffc6428b6907d8bf1b56318acd999d34b056 SHA512 a0d01771c0ca0292bbbb95d77d9369dbf0ebb27693a709e110d3c0924e40b5a1ebdeba39035772269b8f42ddb964eb985778c17b725a7031a5b1c0beb7d582f5 WHIRLPOOL 051b13d4cbc1a4aa454d9782756c5e533add93118f9b5d01de1a77ace2d3eeb7ccc3fb029e1e319cf7887a5182713193ca559d5e8e70508163e77604e1599b06 >+AUX libtirpc-0.2.2-rpc-des-prot.patch 979 SHA256 f09e866816973c6aac5c6e19d3007440b85ff42fe3c36ad0c3ee02dd657eb90c SHA512 18d2941c682c98f0fe940d08f65493b588274d64691cc2c1b939e1054d2b58a576f04c55f97f0d92d16993854dbde17c031f0429f90ae1ead0f01645f17b6513 WHIRLPOOL 9d009725fc2a95005467b7eb921e5c53f9f256ee85e09f36ed8960347da24041c8ddf4762d6d3175b9816cb210c2a89a8afb15f70162417b85ef222df2db8737 >+AUX libtirpc-0.2.5-stdarg.patch 667 SHA256 2b31b1148af9d96c9a9e6f609c0b5b03424954d6251c18d64b6119afd8afa6f7 SHA512 2197f8c2ed3b4dbfc54ee37e973a6e275d19c6dde5d066b9ce45beecdbb17c9e620d7c6f0997b7ebfeb2bd1741327028a793b34edd94d59a89c8b36ac102b025 WHIRLPOOL 90d4e88c18f0d93ab8dfef4981377c2a6df42ff90b70049d07e203e7b66a5087910fe501cf9e1b93782eb25a8b3a8680c03287ccc563b838f517e5d1524b12c5 >+DIST libtirpc-0.2.5.tar.bz2 459094 SHA256 62f9de7c2c8686c568757730e1fef66502a0e00d6cacf33546d0267984e002db SHA512 9f8afa1acb04a2c2c558018f2528f8caaa79994a2af2abeed947f914145872ef72988b241e11925c799db0de9ec51fd9baecd2b08150240b22f91e2e55a45194 WHIRLPOOL a2b4f1c4825f2b774c2290cccd9d552bb7566ec9eb5988d3ab619d7870a907600f67e7af39fbc3e245606db8534f114c990145789c383206d3a9cf96cf043d8c >+DIST libtirpc-glibc-nfs.tar.xz 8948 SHA256 2677cfedf626f3f5a8f6e507aed5bb8f79a7453b589d684dbbc086e755170d83 SHA512 90255bf0a27af16164e0710dd940778609925d473f4343093ff19d98cc4f23023788bf4edf0178eae1961afc0ba8b69b273de95b7d7e2afdb706701d8ba6f7ba WHIRLPOOL 06bcf3fd4e424a86071e5c4ddeb89aa571c862e765aae9382d9f9a55ab72cd1c623490555c1a9bd3380a2d04ecb10fb47a75a7dddf449d4368a1a01617226858 >+EBUILD libtirpc-0.2.5-r99.ebuild 2022 SHA256 c952c25e75474875c3c47920326bd3d2a20f6591df3f08f11cc593f38e37fcff SHA512 01b5736251ba5b56aa50b1882d16026709d58063d9070510cee269b315a8581051b66d853bba06562cce15d2d3d6eafe7782375eb4d6f81f1ef45cfee673018b WHIRLPOOL 23cc692e38df31db8e72b74bb1595eda7dddbb419f668350bfcef7e1a8f1e72ecd8e1657b9da660fe9653ee73dd74e5be3c59fc06574ce69af3d95091102d734 >+MISC ChangeLog 6596 SHA256 d9586ff7ce934567739513273ff6b2a4f7f48d00e9b2900d82a99f082f28441b SHA512 5bd95b49ba599c3cff6e383bc45a2240663976c7c709ce688f749f7f3733c532ca508a21055f8f6b826957da92f256e633c22bddc7cc92c378a4725b09638430 WHIRLPOOL 772e38ee6c50727c15d1968d498317965c4325ecf7f1bb4b49e23235754ba912271448c8e524397700d0a63e771dfe3284df767e836cb7e386020952ee9b7f6d >+MISC metadata.xml 159 SHA256 562c59615c028ffa088de789b3a792fd4cbbbfe71628ddd6a55d3b176becbc6b SHA512 9645bd7d570c2eefd7f14adf726c056a6295d45263f143e365a3fd2e8e6128392eb5fa1103b3a3bb60a622b4595ac7fe3ec19430184210ff63e86d5f03635704 WHIRLPOOL 1d62390192bf65ac30d67f3c0a872536dd8e6a5a0d8d978e5e8f83f09e44907abf16825066c9976e8be482398385737a024837da3c544eaf912ec2710318e289 >diff --git a/net-libs/libtirpc/files/0001-Provide-getrpcbynumber-and-getrpcbyname-if-those-are.patch b/net-libs/libtirpc/files/0001-Provide-getrpcbynumber-and-getrpcbyname-if-those-are.patch >new file mode 100644 >index 0000000..3708638 >--- /dev/null >+++ b/net-libs/libtirpc/files/0001-Provide-getrpcbynumber-and-getrpcbyname-if-those-are.patch >@@ -0,0 +1,85 @@ >+From d3b5ffed6d7d49cc93b2343afcf0e4502a3e54ce Mon Sep 17 00:00:00 2001 >+From: Natanael Copa <ncopa@alpinelinux.org> >+Date: Thu, 24 Apr 2014 09:19:45 +0200 >+Subject: [PATCH 1/2] Provide getrpcbynumber and getrpcbyname if those are >+ missing >+ >+We enable the config.h again and check fi getrpcbynumber and >+getrpcbyname exists on the building patform. If it does not exist, then >+provide those functions. >+ >+This is needed for musl libc. >+--- >+ configure.ac | 6 ++++-- >+ src/getrpcent.c | 10 ++++++++-- >+ 2 files changed, 12 insertions(+), 4 deletions(-) >+ >+diff --git a/configure.ac b/configure.ac >+index 10d17ea..0180801 100644 >+--- a/configure.ac >++++ b/configure.ac >+@@ -24,14 +24,16 @@ if test "x$enable_ipv6" != xno; then >+ fi >+ >+ AC_PROG_CC >+-m4_pattern_allow(AM_CONFIG_HEADERS(config.h)) >++AC_CONFIG_HEADERS([config.h]) >+ AC_PROG_LIBTOOL >+ AC_HEADER_DIRENT >+ AC_PREFIX_DEFAULT(/usr) >+ AC_CHECK_HEADERS([arpa/inet.h fcntl.h libintl.h limits.h locale.h netdb.h netinet/in.h stddef.h stdint.h stdlib.h string.h sys/ioctl.h sys/param.h sys/socket.h sys/time.h syslog.h unistd.h]) >+ AC_CHECK_LIB([pthread], [pthread_create]) >+ AC_CHECK_LIB([nsl], [yp_get_default_domain]) >+- >++AC_CHECK_FUNCS([getrpcbyname getrpcbynumber]) >+ >+ AC_CONFIG_FILES([Makefile src/Makefile man/Makefile doc/Makefile]) >+ AC_OUTPUT(libtirpc.pc) >++ >++ >+diff --git a/src/getrpcent.c b/src/getrpcent.c >+index 1b54b6d..6da006a 100644 >+--- a/src/getrpcent.c >++++ b/src/getrpcent.c >+@@ -50,6 +50,10 @@ >+ #include <libc_private.h> >+ #endif >+ >++#if HAVE_CONFIG_H >++#include "config.h" >++#endif >++ >+ /* >+ * Internet version. >+ */ >+@@ -89,7 +93,7 @@ _rpcdata() >+ return (d); >+ } >+ >+-#ifdef GQ >++#if !HAVE_GETRPCBYNYMBER >+ struct rpcent * >+ getrpcbynumber(number) >+ int number; >+@@ -135,7 +139,9 @@ no_yp: >+ endrpcent(); >+ return (p); >+ } >++#endif /* !HAVE_GETRPCBYNUMBER */ >+ >++#if !HAVE_GETRPCBYNAME >+ struct rpcent * >+ getrpcbyname(name) >+ const char *name; >+@@ -158,7 +164,7 @@ done: >+ endrpcent(); >+ return (rpc); >+ } >+-#endif /* GQ */ >++#endif /* !HAVE_GETRPCBYNAME */ >+ >+ void >+ setrpcent(f) >+-- >+1.9.2 >+ >diff --git a/net-libs/libtirpc/files/0002-Misc-header-fixes.patch b/net-libs/libtirpc/files/0002-Misc-header-fixes.patch >new file mode 100644 >index 0000000..9287d03 >--- /dev/null >+++ b/net-libs/libtirpc/files/0002-Misc-header-fixes.patch >@@ -0,0 +1,40 @@ >+From ed6dc31ed1092baf42f99278ef9c5c297805c3d0 Mon Sep 17 00:00:00 2001 >+From: Natanael Copa <ncopa@alpinelinux.org> >+Date: Thu, 24 Apr 2014 08:58:20 +0200 >+Subject: [PATCH 2/2] Misc header fixes >+ >+src/bindresvport.c: IPPORT_RESERVED needs netdb.h >+ >+Misc fixes for building on musl libc >+--- >+ src/bindresvport.c | 1 + >+ tirpc/netconfig.h | 1 + >+ tirpc/rpc/rpcent.h | 2 +- >+ tirpc/rpc/types.h | 1 + >+ 4 files changed, 4 insertions(+), 1 deletion(-) >+ >+diff --git a/src/bindresvport.c b/src/bindresvport.c >+index d6d9c14..5a7a1a9 100644 >+--- a/src/bindresvport.c >++++ b/src/bindresvport.c >+@@ -37,6 +37,7 @@ >+ #include <sys/types.h> >+ #include <sys/socket.h> >+ >++#include <netdb.h> >+ #include <netinet/in.h> >+ >+ #include <errno.h> >+diff --git a/tirpc/rpc/rpcent.h b/tirpc/rpc/rpcent.h >+index c865e51..a36cf91 100644 >+--- a/tirpc/rpc/rpcent.h >++++ b/tirpc/rpc/rpcent.h >+@@ -47,7 +47,7 @@ >+ __BEGIN_DECLS >+ >+ /* These are defined in /usr/include/rpc/netdb.h */ >+-#if 0 >++#if !defined(__GLIBC__) >+ struct rpcent { >+ char *r_name; /* name of server for this rpc program */ >+ char **r_aliases; /* alias list */ >diff --git a/net-libs/libtirpc/files/0003-fix_cdefs_h_include.patch b/net-libs/libtirpc/files/0003-fix_cdefs_h_include.patch >new file mode 100644 >index 0000000..4f09b70 >--- /dev/null >+++ b/net-libs/libtirpc/files/0003-fix_cdefs_h_include.patch >@@ -0,0 +1,618 @@ >+--- ./tirpc/rpc/xdr.h.orig 2014-11-28 09:09:44.902289976 +0000 >++++ ./tirpc/rpc/xdr.h 2014-11-28 09:09:44.903289976 +0000 >+@@ -40,7 +40,9 @@ >+ >+ #ifndef _TIRPC_XDR_H >+ #define _TIRPC_XDR_H >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ #include <stdio.h> >+ #include <netinet/in.h> >+ >+--- ./tirpc/rpc/pmap_prot.h.orig 2014-11-28 09:09:44.901289976 +0000 >++++ ./tirpc/rpc/pmap_prot.h 2014-11-28 09:09:44.902289976 +0000 >+@@ -71,7 +71,9 @@ >+ >+ #ifndef _RPC_PMAP_PROT_H >+ #define _RPC_PMAP_PROT_H >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ #define PMAPPORT ((u_short)111) >+ #define PMAPPROG ((u_long)100000) >+--- ./tirpc/rpc/auth.h.orig 2014-11-28 09:09:44.896289976 +0000 >++++ ./tirpc/rpc/auth.h 2014-11-28 09:09:44.897289976 +0000 >+@@ -48,7 +48,9 @@ >+ >+ #include <rpc/xdr.h> >+ #include <rpc/clnt_stat.h> >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ #include <sys/socket.h> >+ #include <sys/types.h> >+ >+--- ./tirpc/rpc/svc.h.orig 2014-11-28 09:09:44.904289976 +0000 >++++ ./tirpc/rpc/svc.h 2014-11-28 09:09:44.905289976 +0000 >+@@ -40,7 +40,9 @@ >+ >+ #ifndef _TIRPC_SVC_H >+ #define _TIRPC_SVC_H >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * This interface must manage two items concerning remote procedure calling: >+--- ./tirpc/rpc/svc_soc.h.orig 2014-11-28 09:09:44.906289976 +0000 >++++ ./tirpc/rpc/svc_soc.h 2014-11-28 09:09:44.907289976 +0000 >+@@ -38,7 +38,9 @@ >+ >+ #ifndef _RPC_SVC_SOC_H >+ #define _RPC_SVC_SOC_H >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* #pragma ident "@(#)svc_soc.h 1.11 94/04/25 SMI" */ >+ /* svc_soc.h 1.8 89/05/01 SMI */ >+--- ./tirpc/rpc/clnt_soc.h.orig 2014-11-28 09:09:44.893289976 +0000 >++++ ./tirpc/rpc/clnt_soc.h 2014-11-28 09:09:44.894289976 +0000 >+@@ -46,7 +46,9 @@ >+ * with TS-RPC. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ #define UDPMSGSIZE 8800 /* rpc imposed limit on udp msg size */ >+ >+--- ./tirpc/rpc/rpc_com.h.orig 2014-11-28 09:09:44.894289976 +0000 >++++ ./tirpc/rpc/rpc_com.h 2014-11-28 09:09:44.894289976 +0000 >+@@ -41,7 +41,9 @@ >+ #ifndef _RPC_RPCCOM_H >+ #define _RPC_RPCCOM_H >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* #pragma ident "@(#)rpc_com.h 1.11 93/07/05 SMI" */ >+ >+--- ./tirpc/rpc/auth_unix.h.orig 2014-11-28 09:09:44.905289976 +0000 >++++ ./tirpc/rpc/auth_unix.h 2014-11-28 09:09:44.906289976 +0000 >+@@ -45,7 +45,9 @@ >+ >+ #ifndef _TIRPC_AUTH_UNIX_H >+ #define _TIRPC_AUTH_UNIX_H >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* The machine name is part of a credential; it may not exceed 255 bytes */ >+ #define MAX_MACHINE_NAME 255 >+--- ./tirpc/rpc/pmap_rmt.h.orig 2014-11-28 09:09:44.899289976 +0000 >++++ ./tirpc/rpc/pmap_rmt.h 2014-11-28 09:09:44.900289976 +0000 >+@@ -41,7 +41,9 @@ >+ >+ #ifndef _RPC_PMAP_RMT_H >+ #define _RPC_PMAP_RMT_H >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ struct rmtcallargs { >+ u_long prog, vers, proc, arglen; >+--- ./tirpc/rpc/des_crypt.h.orig 2014-11-28 09:09:44.900289976 +0000 >++++ ./tirpc/rpc/des_crypt.h 2014-11-28 09:09:44.901289976 +0000 >+@@ -43,7 +43,9 @@ >+ #ifndef _DES_DES_CRYPT_H >+ #define _DES_DES_CRYPT_H >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ #include <rpc/rpc.h> >+ >+ #define DES_MAXDATA 8192 /* max bytes encrypted in one call */ >+--- ./tirpc/rpc/clnt.h.orig 2014-11-28 09:09:44.897289976 +0000 >++++ ./tirpc/rpc/clnt.h 2014-11-28 09:09:44.899289976 +0000 >+@@ -42,7 +42,9 @@ >+ #include <rpc/clnt_stat.h> >+ #include <rpc/auth.h> >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ #include <netconfig.h> >+ #include <sys/un.h> >+ >+--- ./tirpc/rpc/pmap_clnt.h.orig 2014-11-28 09:09:44.895289976 +0000 >++++ ./tirpc/rpc/pmap_clnt.h 2014-11-28 09:09:44.895289976 +0000 >+@@ -63,7 +63,9 @@ >+ >+ #ifndef _RPC_PMAP_CLNT_H_ >+ #define _RPC_PMAP_CLNT_H_ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ __BEGIN_DECLS >+ extern bool_t pmap_set(u_long, u_long, int, int); >+--- ./tirpc/rpcsvc/crypt.x.orig 2014-11-28 09:09:44.907289976 +0000 >++++ ./tirpc/rpcsvc/crypt.x 2014-11-28 09:09:44.908289976 +0000 >+@@ -31,7 +31,9 @@ >+ */ >+ >+ #ifndef RPC_HDR >+-%#include <sys/cdefs.h> >++%#ifdef __GLIBC__ >++%#include <sys/cdefs.h> >++%#endif >+ %__FBSDID("$FreeBSD: src/include/rpcsvc/crypt.x,v 1.5 2003/05/04 02:51:42 obrien Exp $"); >+ #endif >+ >+--- ./src/auth_none.c.orig 2014-11-28 09:09:44.875289976 +0000 >++++ ./src/auth_none.c 2014-11-28 09:09:44.876289976 +0000 >+@@ -31,7 +31,9 @@ >+ static char *sccsid = "@(#)auth_none.c 1.19 87/08/11 Copyr 1984 Sun Micro"; >+ static char *sccsid = "@(#)auth_none.c 2.1 88/07/29 4.0 RPCSRC"; >+ #endif >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ __FBSDID("$FreeBSD: src/lib/libc/rpc/auth_none.c,v 1.12 2002/03/22 23:18:35 obrien Exp $"); >+ */ >+ >+--- ./src/crypt_client.c.orig 2014-11-28 09:09:44.886289976 +0000 >++++ ./src/crypt_client.c 2014-11-28 09:09:44.886289976 +0000 >+@@ -30,7 +30,9 @@ >+ * SUCH DAMAGE. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ #include <err.h> >+ #include <sys/types.h> >+--- ./src/xdr_reference.c.orig 2014-11-28 09:09:44.858289976 +0000 >++++ ./src/xdr_reference.c 2014-11-28 09:09:44.859289976 +0000 >+@@ -26,8 +26,12 @@ >+ * POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * xdr_reference.c, Generic XDR routines impelmentation. >+--- ./src/auth_unix.c.orig 2014-11-28 09:09:44.863289976 +0000 >++++ ./src/auth_unix.c 2014-11-28 09:09:44.864289976 +0000 >+@@ -26,7 +26,9 @@ >+ * POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * auth_unix.c, Implements UNIX style authentication parameters. >+--- ./src/authdes_prot.c.orig 2014-11-28 09:09:44.868289976 +0000 >++++ ./src/authdes_prot.c 2014-11-28 09:09:44.869289976 +0000 >+@@ -1,4 +1,6 @@ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ /* >+ * Copyright (c) 2009, Sun Microsystems, Inc. >+ * All rights reserved. >+--- ./src/rpcb_st_xdr.c.orig 2014-11-28 09:09:44.847289976 +0000 >++++ ./src/rpcb_st_xdr.c 2014-11-28 09:09:44.848289976 +0000 >+@@ -35,7 +35,9 @@ >+ * routines used with the rpcbind stats facility. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ #include <rpc/rpc.h> >+ >+--- ./src/auth_time.c.orig 2014-11-28 09:09:44.887289976 +0000 >++++ ./src/auth_time.c 2014-11-28 09:09:44.888289976 +0000 >+@@ -25,7 +25,9 @@ >+ * needed to deal with TCP connections. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ #include <stdio.h> >+ #include <syslog.h> >+ #include <string.h> >+--- ./src/des_crypt.c.orig 2014-11-28 09:09:44.871289976 +0000 >++++ ./src/des_crypt.c 2014-11-28 09:09:44.872289976 +0000 >+@@ -39,7 +39,9 @@ >+ static char sccsid[] = "@(#)des_crypt.c 2.2 88/08/10 4.0 RPCSRC; from 1.13 88/02/08 SMI"; >+ #endif >+ #endif >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ static int common_crypt( char *, char *, unsigned, unsigned, struct desparams * ); >+ int (*__des_crypt_LOCAL)() = 0; >+--- ./src/svc_vc.c.orig 2014-11-28 09:09:44.878289976 +0000 >++++ ./src/svc_vc.c 2014-11-28 09:09:44.879289976 +0000 >+@@ -27,7 +27,9 @@ >+ * POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * svc_vc.c, Server side for Connection Oriented based RPC. >+--- ./src/xdr_float.c.orig 2014-11-28 09:09:44.882289976 +0000 >++++ ./src/xdr_float.c 2014-11-28 09:09:44.883289976 +0000 >+@@ -27,7 +27,9 @@ >+ * POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * xdr_float.c, Generic XDR routines implementation. >+--- ./src/xdr_sizeof.c.orig 2014-11-28 09:09:44.865289976 +0000 >++++ ./src/xdr_sizeof.c 2014-11-28 09:09:44.866289976 +0000 >+@@ -34,7 +34,9 @@ >+ * when serialized using XDR. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ #include <rpc/types.h> >+ #include <rpc/xdr.h> >+--- ./src/xdr_array.c.orig 2014-11-28 09:09:44.892289976 +0000 >++++ ./src/xdr_array.c 2014-11-28 09:09:44.893289976 +0000 >+@@ -27,7 +27,9 @@ >+ * POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * xdr_array.c, Generic XDR routines impelmentation. >+--- ./src/rpc_generic.c.orig 2014-11-28 09:09:44.842289976 +0000 >++++ ./src/rpc_generic.c 2014-11-28 09:09:44.844289976 +0000 >+@@ -29,7 +29,9 @@ >+ * Copyright (c) 1986-1991 by Sun Microsystems Inc. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * rpc_generic.c, Miscl routines for RPC. >+--- ./src/getpeereid.c.orig 2014-11-28 09:09:44.855289976 +0000 >++++ ./src/getpeereid.c 2014-11-28 09:09:44.856289976 +0000 >+@@ -24,7 +24,9 @@ >+ * SUCH DAMAGE. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ #include <sys/param.h> >+ #include <sys/socket.h> >+--- ./src/xdr_stdio.c.orig 2014-11-28 09:09:44.880289976 +0000 >++++ ./src/xdr_stdio.c 2014-11-28 09:09:44.881289976 +0000 >+@@ -26,7 +26,9 @@ >+ * POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * xdr_stdio.c, XDR implementation on standard i/o file. >+--- ./src/clnt_bcast.c.orig 2014-11-28 09:09:44.859289976 +0000 >++++ ./src/clnt_bcast.c 2014-11-28 09:09:44.861289976 +0000 >+@@ -28,7 +28,9 @@ >+ /* >+ * Copyright (c) 1986-1991 by Sun Microsystems Inc. >+ */ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * clnt_bcast.c >+--- ./src/xdr_mem.c.orig 2014-11-28 09:09:44.876289976 +0000 >++++ ./src/xdr_mem.c 2014-11-28 09:09:44.877289976 +0000 >+@@ -26,7 +26,9 @@ >+ * POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * xdr_mem.h, XDR implementation using memory buffers. >+--- ./src/key_call.c.orig 2014-11-28 09:09:44.889289976 +0000 >++++ ./src/key_call.c 2014-11-28 09:09:44.890289976 +0000 >+@@ -30,7 +30,9 @@ >+ */ >+ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * key_call.c, Interface to keyserver >+--- ./src/svc_simple.c.orig 2014-11-28 09:09:44.874289976 +0000 >++++ ./src/svc_simple.c 2014-11-28 09:09:44.875289976 +0000 >+@@ -29,7 +29,9 @@ >+ * Copyright (c) 1986-1991 by Sun Microsystems Inc. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * svc_simple.c >+--- ./src/mt_misc.c.orig 2014-11-28 09:09:44.870289976 +0000 >++++ ./src/mt_misc.c 2014-11-28 09:09:44.871289976 +0000 >+@@ -1,5 +1,7 @@ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ #include <pthread.h> >+ #include <reentrant.h> >+ #include <rpc/rpc.h> >+--- ./src/authunix_prot.c.orig 2014-11-28 09:09:44.885289976 +0000 >++++ ./src/authunix_prot.c 2014-11-28 09:09:44.885289976 +0000 >+@@ -26,7 +26,9 @@ >+ * POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * authunix_prot.c >+--- ./src/des_soft.c.orig 2014-11-28 09:09:44.851289976 +0000 >++++ ./src/des_soft.c 2014-11-28 09:09:44.851289976 +0000 >+@@ -1,4 +1,6 @@ >+-//#include <sys/cdefs.h> >++//#ifdef __GLIBC__ >++#include <sys/cdefs.h> >++#endif >+ >+ /* >+ * Copyright (c) 2009, Sun Microsystems, Inc. >+--- ./src/rpcdname.c.orig 2014-11-28 09:09:44.850289976 +0000 >++++ ./src/rpcdname.c 2014-11-28 09:09:44.850289976 +0000 >+@@ -25,7 +25,9 @@ >+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE >+ * POSSIBILITY OF SUCH DAMAGE. >+ */ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * rpcdname.c >+--- ./src/getnetpath.c.orig 2014-11-28 09:09:44.884289976 +0000 >++++ ./src/getnetpath.c 2014-11-28 09:09:44.884289976 +0000 >+@@ -25,13 +25,17 @@ >+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE >+ * POSSIBILITY OF SUCH DAMAGE. >+ */ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * Copyright (c) 1989 by Sun Microsystems, Inc. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ #include <stdio.h> >+ #include <errno.h> >+ #include <netconfig.h> >+--- ./src/svc_dg.c.orig 2014-11-28 09:09:44.852289976 +0000 >++++ ./src/svc_dg.c 2014-11-28 09:09:44.853289976 +0000 >+@@ -31,7 +31,9 @@ >+ * Copyright (c) 1986-1991 by Sun Microsystems Inc. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * svc_dg.c, Server side for connectionless RPC. >+--- ./src/rpc_com.h.orig 2014-11-28 09:09:44.845289976 +0000 >++++ ./src/rpc_com.h 2014-11-28 09:09:44.846289976 +0000 >+@@ -40,7 +40,9 @@ >+ #ifndef _TIRPC_RPCCOM_H >+ #define _TIRPC_RPCCOM_H >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* #pragma ident "@(#)rpc_com.h 1.11 93/07/05 SMI" */ >+ >+--- ./src/pmap_getmaps.c.orig 2014-11-28 09:09:44.891289976 +0000 >++++ ./src/pmap_getmaps.c 2014-11-28 09:09:44.892289976 +0000 >+@@ -26,7 +26,9 @@ >+ * POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * pmap_getmap.c >+--- ./src/pmap_clnt.c.orig 2014-11-28 09:09:44.869289976 +0000 >++++ ./src/pmap_clnt.c 2014-11-28 09:09:44.870289976 +0000 >+@@ -26,7 +26,9 @@ >+ * POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * pmap_clnt.c >+--- ./src/bindresvport.c.orig 2014-11-28 09:09:44.848289976 +0000 >++++ ./src/bindresvport.c 2014-11-28 09:09:44.849289976 +0000 >+@@ -26,7 +26,9 @@ >+ * POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * Copyright (c) 1987 by Sun Microsystems, Inc. >+--- ./src/xdr_rec.c.orig 2014-11-28 09:09:44.866289976 +0000 >++++ ./src/xdr_rec.c 2014-11-28 09:09:44.868289976 +0000 >+@@ -27,8 +27,12 @@ >+ * POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * xdr_rec.c, Implements TCP/IP based XDR streams with a "record marking" >+--- ./src/clnt_perror.c.orig 2014-11-28 09:09:44.854289976 +0000 >++++ ./src/clnt_perror.c 2014-11-28 09:09:44.855289976 +0000 >+@@ -27,7 +27,9 @@ >+ */ >+ >+ /* >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ */ >+ /* >+ * clnt_perror.c >+--- ./src/key_prot_xdr.c.orig 2014-11-28 09:09:44.888289976 +0000 >++++ ./src/key_prot_xdr.c 2014-11-28 09:09:44.889289976 +0000 >+@@ -33,7 +33,9 @@ >+ */ >+ /* Copyright (c) 1990, 1991 Sun Microsystems, Inc. */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * Compiled from key_prot.x using rpcgen. >+--- ./src/getnetconfig.c.orig 2014-11-28 09:09:44.856289976 +0000 >++++ ./src/getnetconfig.c 2014-11-28 09:09:44.858289976 +0000 >+@@ -32,7 +32,9 @@ >+ >+ #include <pthread.h> >+ #include <reentrant.h> >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ #include <stdio.h> >+ #include <errno.h> >+ #include <netconfig.h> >+--- ./src/getpublickey.c.orig 2014-11-28 09:09:44.844289976 +0000 >++++ ./src/getpublickey.c 2014-11-28 09:09:44.845289976 +0000 >+@@ -26,7 +26,9 @@ >+ * POSSIBILITY OF SUCH DAMAGE. >+ */ >+ /* >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ */ >+ >+ /* >+--- ./src/clnt_simple.c.orig 2014-11-28 09:09:44.881289976 +0000 >++++ ./src/clnt_simple.c 2014-11-28 09:09:44.882289976 +0000 >+@@ -29,7 +29,9 @@ >+ * Copyright (c) 1986-1991 by Sun Microsystems Inc. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * clnt_simple.c >+--- ./src/auth_des.c.orig 2014-11-28 09:09:44.872289976 +0000 >++++ ./src/auth_des.c 2014-11-28 09:09:44.874289976 +0000 >+@@ -38,7 +38,9 @@ >+ #include <string.h> >+ #include <stdlib.h> >+ #include <unistd.h> >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ #include <rpc/des_crypt.h> >+ #include <syslog.h> >+ #include <rpc/types.h> >+@@ -52,7 +54,9 @@ >+ >+ #if defined(LIBC_SCCS) && !defined(lint) >+ #endif >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ #include "debug.h" >+ >+--- ./src/xdr.c.orig 2014-11-28 09:09:44.861289976 +0000 >++++ ./src/xdr.c 2014-11-28 09:09:44.863289976 +0000 >+@@ -26,7 +26,9 @@ >+ * POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >++#ifdef __GLIBC__ >+ #include <sys/cdefs.h> >++#endif >+ >+ /* >+ * xdr.c, Generic XDR routines implementation. >diff --git a/net-libs/libtirpc/files/0004-fix_DECLS.patch b/net-libs/libtirpc/files/0004-fix_DECLS.patch >new file mode 100644 >index 0000000..86abf77 >--- /dev/null >+++ b/net-libs/libtirpc/files/0004-fix_DECLS.patch >@@ -0,0 +1,1226 @@ >+--- ./tirpc/rpc/xdr.h.orig 2014-11-28 09:16:53.990289976 +0000 >++++ ./tirpc/rpc/xdr.h 2014-11-28 09:16:53.991289976 +0000 >+@@ -289,7 +289,11 @@ struct xdr_discrim { >+ /* >+ * These are the "generic" xdr routines. >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern bool_t xdr_void(void); >+ extern bool_t xdr_int(XDR *, int *); >+ extern bool_t xdr_u_int(XDR *, u_int *); >+@@ -332,7 +336,11 @@ extern bool_t xdr_hyper(XDR *, quad_t *) >+ extern bool_t xdr_u_hyper(XDR *, u_quad_t *); >+ extern bool_t xdr_longlong_t(XDR *, quad_t *); >+ extern bool_t xdr_u_longlong_t(XDR *, u_quad_t *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Common opaque bytes objects used by many rpc protocols; >+@@ -350,7 +358,11 @@ extern bool_t xdr_netobj(XDR *, struct >+ * These are the public routines for the various implementations of >+ * xdr streams. >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ /* XDR using memory buffers */ >+ extern void xdrmem_create(XDR *, char *, u_int, enum xdr_op); >+ >+@@ -371,6 +383,10 @@ extern bool_t xdrrec_skiprecord(XDR *); >+ /* true if no more input */ >+ extern bool_t xdrrec_eof(XDR *); >+ extern u_int xdrrec_readbytes(XDR *, caddr_t, u_int); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* !_TIRPC_XDR_H */ >+--- ./tirpc/rpc/auth_des.h.orig 2014-11-28 09:16:53.994289976 +0000 >++++ ./tirpc/rpc/auth_des.h 2014-11-28 09:16:53.995289976 +0000 >+@@ -114,17 +114,33 @@ struct authdes_verf { >+ * Map a des credential into a unix cred. >+ * >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern int authdes_getucred( struct authdes_cred *, uid_t *, gid_t *, int *, gid_t * ); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern bool_t xdr_authdes_cred(XDR *, struct authdes_cred *); >+ extern bool_t xdr_authdes_verf(XDR *, struct authdes_verf *); >+ extern int rtime(dev_t, struct netbuf *, int, struct timeval *, >+ struct timeval *); >+ extern void kgetnetname(char *); >+ extern enum auth_stat _svcauth_des(struct svc_req *, struct rpc_msg *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* ndef _TI_AUTH_DES_ */ >+--- ./tirpc/rpc/pmap_prot.h.orig 2014-11-28 09:16:53.988289976 +0000 >++++ ./tirpc/rpc/pmap_prot.h 2014-11-28 09:16:53.989289976 +0000 >+@@ -99,10 +99,18 @@ struct pmaplist { >+ struct pmaplist *pml_next; >+ }; >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern bool_t xdr_pmap(XDR *, struct pmap *); >+ extern bool_t xdr_pmaplist(XDR *, struct pmaplist **); >+ extern bool_t xdr_pmaplist_ptr(XDR *, struct pmaplist *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* !_RPC_PMAP_PROT_H */ >+--- ./tirpc/rpc/auth.h.orig 2014-11-28 09:16:53.982289976 +0000 >++++ ./tirpc/rpc/auth.h 2014-11-28 09:16:53.983289976 +0000 >+@@ -166,9 +166,17 @@ union des_block { >+ char c[8]; >+ }; >+ typedef union des_block des_block; >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern bool_t xdr_des_block(XDR *, des_block *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Authentication info. Opaque to client. >+@@ -279,9 +287,17 @@ auth_put(AUTH *auth) >+ xfunc, xwhere)) >+ >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern struct opaque_auth _null_auth; >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Any style authentication. These routines can be used by any >+@@ -302,11 +318,19 @@ int authany_wrap(void), authany_unwrap(v >+ * int len; >+ * int *aup_gids; >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern AUTH *authunix_create(char *, uid_t, uid_t, int, uid_t *); >+ extern AUTH *authunix_create_default(void); /* takes no parameters */ >+ extern AUTH *authnone_create(void); /* takes no parameters */ >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ /* >+ * DES style authentication >+ * AUTH *authsecdes_create(servername, window, timehost, ckey) >+@@ -315,15 +339,31 @@ __END_DECLS >+ * const char *timehost; - optional hostname to sync with >+ * des_block *ckey; - optional conversation key to use >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern AUTH *authdes_create (char *, u_int, struct sockaddr *, des_block *); >+ extern AUTH *authdes_seccreate (const char *, const u_int, const char *, >+ const des_block *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern bool_t xdr_opaque_auth (XDR *, struct opaque_auth *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #define authsys_create(c,i1,i2,i3,ip) authunix_create((c),(i1),(i2),(i3),(ip)) >+ #define authsys_create_default() authunix_create_default() >+@@ -331,36 +371,60 @@ __END_DECLS >+ /* >+ * Netname manipulation routines. >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern int getnetname(char *); >+ extern int host2netname(char *, const char *, const char *); >+ extern int user2netname(char *, const uid_t, const char *); >+ extern int netname2user(char *, uid_t *, gid_t *, int *, gid_t *); >+ extern int netname2host(char *, char *, const int); >+ extern void passwd2des ( char *, char * ); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * >+ * These routines interface to the keyserv daemon >+ * >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern int key_decryptsession(const char *, des_block *); >+ extern int key_encryptsession(const char *, des_block *); >+ extern int key_gendes(des_block *); >+ extern int key_setsecret(const char *); >+ extern int key_secretkey_is_set(void); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Publickey routines. >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern int getpublickey (const char *, char *); >+ extern int getpublicandprivatekey (char *, char *); >+ extern int getsecretkey (char *, char *, char *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #ifdef KERBEROS >+ /* >+@@ -373,10 +437,18 @@ __END_DECLS >+ * const char *timehost; - optional hostname to sync with >+ * int *status; - kerberos status returned >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern AUTH *authkerb_seccreate(const char *, const char *, const char *, >+ const u_int, const char *, int *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Map a kerberos credential into a unix cred. >+@@ -389,20 +461,36 @@ __END_DECLS >+ * int *groups; >+ * >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern int authkerb_getucred(/* struct svc_req *, uid_t *, gid_t *, >+ short *, int * */); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ #endif /* KERBEROS */ >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ struct svc_req; >+ struct rpc_msg; >+ enum auth_stat _svcauth_none (struct svc_req *, struct rpc_msg *); >+ enum auth_stat _svcauth_short (struct svc_req *, struct rpc_msg *); >+ enum auth_stat _svcauth_unix (struct svc_req *, struct rpc_msg *); >+ enum auth_stat _svcauth_gss (struct svc_req *, struct rpc_msg *, bool_t *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #define AUTH_NONE 0 /* no authentication */ >+ #define AUTH_NULL 0 /* backward compatibility */ >+--- ./tirpc/rpc/svc.h.orig 2014-11-28 09:16:53.992289976 +0000 >++++ ./tirpc/rpc/svc.h 2014-11-28 09:16:53.993289976 +0000 >+@@ -202,11 +202,19 @@ struct svc_req { >+ * const struct netconfig *nconf; >+ */ >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern bool_t svc_reg(SVCXPRT *, const rpcprog_t, const rpcvers_t, >+ void (*)(struct svc_req *, SVCXPRT *), >+ const struct netconfig *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Service un-registration >+@@ -216,9 +224,17 @@ __END_DECLS >+ * const rpcvers_t vers; >+ */ >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern void svc_unreg(const rpcprog_t, const rpcvers_t); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Transport registration. >+@@ -226,9 +242,17 @@ __END_DECLS >+ * xprt_register(xprt) >+ * SVCXPRT *xprt; >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern void xprt_register(SVCXPRT *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Transport un-register >+@@ -236,9 +260,17 @@ __END_DECLS >+ * xprt_unregister(xprt) >+ * SVCXPRT *xprt; >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern void xprt_unregister(SVCXPRT *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ >+ /* >+@@ -267,7 +299,11 @@ __END_DECLS >+ * deadlock the caller and server processes! >+ */ >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern bool_t svc_sendreply(SVCXPRT *, xdrproc_t, void *); >+ extern void svcerr_decode(SVCXPRT *); >+ extern void svcerr_weakauth(SVCXPRT *); >+@@ -279,7 +315,11 @@ extern void svcerr_systemerr(SVCXPRT *); >+ extern int rpc_reg(rpcprog_t, rpcvers_t, rpcproc_t, >+ char *(*)(char *), xdrproc_t, xdrproc_t, >+ char *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Lowest level dispatching -OR- who owns this process anyway. >+@@ -308,11 +348,23 @@ extern int svc_fds; >+ * a small program implemented by the svc_rpc implementation itself; >+ * also see clnt.h for protocol numbers. >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern void rpctest_service(void); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern void svc_getreq(int); >+ extern void svc_getreqset(fd_set *); >+ extern void svc_getreq_common(int); >+@@ -321,7 +373,11 @@ extern void svc_getreq_poll(struct pollf >+ >+ extern void svc_run(void); >+ extern void svc_exit(void); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Socket to use on svcxxx_create call to get default socket >+@@ -333,7 +389,11 @@ __END_DECLS >+ * These are the existing service side transport implementations >+ */ >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ /* >+ * Transport independent svc_create routine. >+ */ >+@@ -429,7 +489,11 @@ int svc_dg_enablecache(SVCXPRT *, const >+ >+ int __rpc_get_local_uid(SVCXPRT *_transp, uid_t *_uid); >+ >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ >+ /* for backward compatibility */ >+--- ./tirpc/rpc/rpc.h.orig 2014-11-28 09:16:53.994289976 +0000 >++++ ./tirpc/rpc/rpc.h 2014-11-28 09:16:53.994289976 +0000 >+@@ -79,7 +79,11 @@ >+ #define UDPMSGSIZE 8800 >+ #endif >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern int get_myaddress(struct sockaddr_in *); >+ extern int bindresvport(int, struct sockaddr_in *) __THROW; >+ extern int registerrpc(int, int, int, char *(*)(char [UDPMSGSIZE]), >+@@ -93,18 +97,30 @@ struct netbuf *uaddr2taddr(const struct >+ >+ struct sockaddr; >+ extern int bindresvport_sa(int, struct sockaddr *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * The following are not exported interfaces, they are for internal library >+ * and rpcbind use only. Do not use, they may change without notice. >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ int __rpc_nconf2fd(const struct netconfig *); >+ int __rpc_nconf2fd_flags(const struct netconfig *, int); >+ int __rpc_nconf2sockinfo(const struct netconfig *, struct __rpc_sockinfo *); >+ int __rpc_fd2sockinfo(int, struct __rpc_sockinfo *); >+ u_int __rpc_get_t_size(int, int, int); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* !_RPC_RPC_H */ >+--- ./tirpc/rpc/svc_soc.h.orig 2014-11-28 09:16:53.998289976 +0000 >++++ ./tirpc/rpc/svc_soc.h 2014-11-28 09:16:53.999289976 +0000 >+@@ -66,10 +66,18 @@ >+ * void (*dispatch)(); >+ * int protocol; like TCP or UDP, zero means do not register >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern bool_t svc_register(SVCXPRT *, u_long, u_long, >+ void (*)(struct svc_req *, SVCXPRT *), int); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Service un-registration >+@@ -78,44 +86,84 @@ __END_DECLS >+ * u_long prog; >+ * u_long vers; >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern void svc_unregister(u_long, u_long); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ >+ /* >+ * Memory based rpc for testing and timing. >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern SVCXPRT *svcraw_create(void); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ >+ /* >+ * Udp based rpc. >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern SVCXPRT *svcudp_create(int); >+ extern SVCXPRT *svcudp_bufcreate(int, u_int, u_int); >+ extern int svcudp_enablecache(SVCXPRT *, u_long); >+ extern SVCXPRT *svcudp6_create(int); >+ extern SVCXPRT *svcudp6_bufcreate(int, u_int, u_int); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ >+ /* >+ * Tcp based rpc. >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern SVCXPRT *svctcp_create(int, u_int, u_int); >+ extern SVCXPRT *svctcp6_create(int, u_int, u_int); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Fd based rpc. >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern SVCXPRT *svcfd_create(int, u_int, u_int); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* !_RPC_SVC_SOC_H */ >+--- ./tirpc/rpc/clnt_soc.h.orig 2014-11-28 09:16:53.976289976 +0000 >++++ ./tirpc/rpc/clnt_soc.h 2014-11-28 09:16:53.977289976 +0000 >+@@ -63,27 +63,51 @@ >+ * u_int sendsz; >+ * u_int recvsz; >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern CLIENT *clnttcp_create(struct sockaddr_in *, u_long, u_long, int *, >+ u_int, u_int); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Raw (memory) rpc. >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern CLIENT *clntraw_create(u_long, u_long); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ >+ /* >+ IPv6 socket version >+ */ >+ #ifdef INET6 >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern CLIENT *clnttcp6_create(struct sockaddr_in6 *, u_long, u_long, int *, >+ u_int, u_int); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ #endif >+ >+ /* >+@@ -107,7 +131,11 @@ __END_DECLS >+ * u_int sendsz; >+ * u_int recvsz; >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern CLIENT *clntudp_create(struct sockaddr_in *, u_long, u_long, >+ struct timeval, int *); >+ extern CLIENT *clntudp_bufcreate(struct sockaddr_in *, u_long, u_long, >+@@ -118,7 +146,11 @@ extern CLIENT *clntudp6_create(struct so >+ extern CLIENT *clntudp6_bufcreate(struct sockaddr_in6 *, u_long, u_long, >+ struct timeval, int *, u_int, u_int); >+ #endif >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ >+ #endif /* _RPC_CLNT_SOC_H */ >+--- ./tirpc/rpc/rpc_com.h.orig 2014-11-28 09:16:53.977289976 +0000 >++++ ./tirpc/rpc/rpc_com.h 2014-11-28 09:16:53.978289976 +0000 >+@@ -57,7 +57,11 @@ >+ #define __RPC_GETXID(now) ((u_int32_t)getpid() ^ (u_int32_t)(now)->tv_sec ^ \ >+ (u_int32_t)(now)->tv_usec) >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern u_int __rpc_get_a_size(int); >+ extern int __rpc_dtbsize(void); >+ extern int _rpc_dtablesize(void); >+@@ -79,6 +83,10 @@ bool_t rpc_control(int,void *); >+ >+ char *_get_next_token(char *, int); >+ >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* _RPC_RPCCOM_H */ >+--- ./tirpc/rpc/auth_unix.h.orig 2014-11-28 09:16:53.998289976 +0000 >++++ ./tirpc/rpc/auth_unix.h 2014-11-28 09:16:53.998289976 +0000 >+@@ -69,9 +69,17 @@ struct authunix_parms { >+ >+ #define authsys_parms authunix_parms >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern bool_t xdr_authunix_parms(XDR *, struct authunix_parms *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * If a response verifier has flavor AUTH_SHORT, >+--- ./tirpc/rpc/pmap_rmt.h.orig 2014-11-28 09:16:53.986289976 +0000 >++++ ./tirpc/rpc/pmap_rmt.h 2014-11-28 09:16:53.986289976 +0000 >+@@ -58,9 +58,17 @@ struct rmtcallres { >+ xdrproc_t xdr_results; >+ }; >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern bool_t xdr_rmtcall_args(XDR *, struct rmtcallargs *); >+ extern bool_t xdr_rmtcallres(XDR *, struct rmtcallres *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* !_RPC_PMAP_RMT_H */ >+--- ./tirpc/rpc/des_crypt.h.orig 2014-11-28 09:16:53.987289976 +0000 >++++ ./tirpc/rpc/des_crypt.h 2014-11-28 09:16:53.988289976 +0000 >+@@ -85,23 +85,47 @@ >+ /* >+ * Cipher Block Chaining mode >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ int cbc_crypt( char *, char *, unsigned int, unsigned int, char *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Electronic Code Book mode >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ int ecb_crypt( char *, char *, unsigned int, unsigned int ); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Set des parity for a key. >+ * DES parity is odd and in the low bit of each byte >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ void des_setparity( char *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* _DES_DES_CRYPT_H */ >+--- ./tirpc/rpc/rpcb_clnt.h.orig 2014-11-28 09:16:53.979289976 +0000 >++++ ./tirpc/rpc/rpcb_clnt.h 2014-11-28 09:16:53.979289976 +0000 >+@@ -59,7 +59,11 @@ >+ >+ #include <rpc/types.h> >+ #include <rpc/rpcb_prot.h> >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern bool_t rpcb_set(const rpcprog_t, const rpcvers_t, >+ const struct netconfig *, const struct netbuf *); >+ extern bool_t rpcb_unset(const rpcprog_t, const rpcvers_t, >+@@ -78,6 +82,10 @@ extern bool_t rpcb_getaddr(const rpcprog >+ extern bool_t rpcb_gettime(const char *, time_t *); >+ extern char *rpcb_taddr2uaddr(struct netconfig *, struct netbuf *); >+ extern struct netbuf *rpcb_uaddr2taddr(struct netconfig *, char *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* !_RPC_RPCB_CLNT_H */ >+--- ./tirpc/rpc/clnt.h.orig 2014-11-28 09:16:53.984289976 +0000 >++++ ./tirpc/rpc/clnt.h 2014-11-28 09:16:53.985289976 +0000 >+@@ -269,7 +269,11 @@ struct rpc_timers { >+ * Generic client creation routine. Supported protocols are those that >+ * belong to the nettype namespace (/etc/netconfig). >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern CLIENT *clnt_create(const char *, const rpcprog_t, const rpcvers_t, >+ const char *); >+ /* >+@@ -416,32 +420,60 @@ extern CLIENT *clnt_dg_create(const int, >+ */ >+ extern CLIENT *clnt_raw_create(rpcprog_t, rpcvers_t); >+ >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ >+ /* >+ * Print why creation failed >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern void clnt_pcreateerror(const char *); /* stderr */ >+ extern char *clnt_spcreateerror(const char *); /* string */ >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Like clnt_perror(), but is more verbose in its output >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern void clnt_perrno(enum clnt_stat); /* stderr */ >+ extern char *clnt_sperrno(enum clnt_stat); /* string */ >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * Print an English error message, given the client error code >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern void clnt_perror(CLIENT *, const char *); /* stderr */ >+ extern char *clnt_sperror(CLIENT *, const char *); /* string */ >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ >+ /* >+@@ -452,9 +484,17 @@ struct rpc_createerr { >+ struct rpc_err cf_error; /* useful when cf_stat == RPC_PMAPFAILURE */ >+ }; >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern struct rpc_createerr *__rpc_createerr(void); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ #define get_rpc_createerr() (*(__rpc_createerr())) >+ #define rpc_createerr (*(__rpc_createerr())) >+ >+@@ -471,12 +511,20 @@ __END_DECLS >+ * char *out; >+ * const char *nettype; >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern enum clnt_stat rpc_call(const char *, const rpcprog_t, >+ const rpcvers_t, const rpcproc_t, >+ const xdrproc_t, const char *, >+ const xdrproc_t, char *, const char *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* >+ * RPC broadcast interface >+@@ -524,7 +572,11 @@ __END_DECLS >+ >+ typedef bool_t (*resultproc_t)(caddr_t, ...); >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern enum clnt_stat rpc_broadcast(const rpcprog_t, const rpcvers_t, >+ const rpcproc_t, const xdrproc_t, >+ caddr_t, const xdrproc_t, caddr_t, >+@@ -534,7 +586,11 @@ extern enum clnt_stat rpc_broadcast_exp( >+ caddr_t, const xdrproc_t, caddr_t, >+ const resultproc_t, const int, >+ const int, const char *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ /* For backward compatibility */ >+ #include <rpc/clnt_soc.h> >+--- ./tirpc/rpc/rpcent.h.orig 2014-11-28 09:16:53.996289976 +0000 >++++ ./tirpc/rpc/rpcent.h 2014-11-28 09:16:53.996289976 +0000 >+@@ -44,7 +44,11 @@ >+ /* #pragma ident "@(#)rpcent.h 1.13 94/04/25 SMI" */ >+ /* @(#)rpcent.h 1.1 88/12/06 SMI */ >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ >+ /* These are defined in /usr/include/rpc/netdb.h */ >+ #if 0 >+@@ -62,6 +66,10 @@ extern struct rpcent *getrpcent(void); >+ >+ extern void setrpcent(int) __THROW; >+ extern void endrpcent(void) __THROW; >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* !_RPC_CENT_H */ >+--- ./tirpc/rpc/pmap_clnt.h.orig 2014-11-28 09:16:53.980289976 +0000 >++++ ./tirpc/rpc/pmap_clnt.h 2014-11-28 09:16:53.980289976 +0000 >+@@ -67,7 +67,11 @@ >+ #include <sys/cdefs.h> >+ #endif >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern bool_t pmap_set(u_long, u_long, int, int); >+ extern bool_t pmap_unset(u_long, u_long); >+ extern struct pmaplist *pmap_getmaps(struct sockaddr_in *); >+@@ -82,6 +86,10 @@ extern enum clnt_stat clnt_broadcast(u_l >+ resultproc_t); >+ extern u_short pmap_getport(struct sockaddr_in *, >+ u_long, u_long, u_int); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* !_RPC_PMAP_CLNT_H_ */ >+--- ./tirpc/rpc/auth_gss.h.orig 2014-11-28 09:16:53.989289976 +0000 >++++ ./tirpc/rpc/auth_gss.h 2014-11-28 09:16:53.990289976 +0000 >+@@ -104,7 +104,11 @@ struct rpc_gss_init_res { >+ #define MAXSEQ 0x80000000 >+ >+ /* Prototypes. */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ bool_t xdr_rpc_gss_cred __P((XDR *xdrs, struct rpc_gss_cred *p)); >+ bool_t xdr_rpc_gss_init_args __P((XDR *xdrs, gss_buffer_desc *p)); >+ bool_t xdr_rpc_gss_init_res __P((XDR *xdrs, struct rpc_gss_init_res *p)); >+@@ -126,6 +130,10 @@ void gss_log_status __P((char *m, OM_ui >+ OM_uint32 minor)); >+ void gss_log_hexdump __P((const u_char *buf, int len, int offset)); >+ >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* !_TIRPC_AUTH_GSS_H */ >+--- ./tirpc/rpc/rpc_msg.h.orig 2014-11-28 09:16:53.996289976 +0000 >++++ ./tirpc/rpc/rpc_msg.h 2014-11-28 09:16:53.997289976 +0000 >+@@ -161,7 +161,11 @@ struct rpc_msg { >+ #define acpted_rply ru.RM_rmb.ru.RP_ar >+ #define rjcted_rply ru.RM_rmb.ru.RP_dr >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ /* >+ * XDR routine to handle a rpc message. >+ * xdr_callmsg(xdrs, cmsg) >+@@ -210,6 +214,10 @@ extern bool_t xdr_rejected_reply(XDR *, >+ * struct rpc_err *error; >+ */ >+ extern void _seterr_reply(struct rpc_msg *, struct rpc_err *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* !_TIRPC_RPC_MSG_H */ >+--- ./tirpc/rpc/nettype.h.orig 2014-11-28 09:16:53.981289976 +0000 >++++ ./tirpc/rpc/nettype.h 2014-11-28 09:16:53.982289976 +0000 >+@@ -53,11 +53,19 @@ >+ #define _RPC_TCP 7 >+ #define _RPC_UDP 8 >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern void *__rpc_setconf(const char *); >+ extern void __rpc_endconf(void *); >+ extern struct netconfig *__rpc_getconf(void *); >+ extern struct netconfig *__rpc_getconfip(const char *); >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* !_TIRPC_NETTYPE_H */ >+--- ./tirpc/rpc/svc_auth.h.orig 2014-11-28 09:16:53.986289976 +0000 >++++ ./tirpc/rpc/svc_auth.h 2014-11-28 09:16:53.987289976 +0000 >+@@ -65,13 +65,21 @@ typedef struct SVCAUTH { >+ /* >+ * Server side authenticator >+ */ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern enum auth_stat _gss_authenticate(struct svc_req *, struct rpc_msg *, >+ bool_t *); >+ extern enum auth_stat _authenticate(struct svc_req *, struct rpc_msg *); >+ extern int svc_auth_reg(int, enum auth_stat (*)(struct svc_req *, >+ struct rpc_msg *)); >+ >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* !_RPC_SVC_AUTH_H */ >+--- ./tirpc/rpcsvc/nis.h.orig 2014-11-28 09:16:54.001289976 +0000 >++++ ./tirpc/rpcsvc/nis.h 2014-11-28 09:16:54.002289976 +0000 >+@@ -36,7 +36,11 @@ >+ #include <rpc/rpc.h> >+ #include <rpcsvc/nis_tags.h> >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ >+ /* >+ * nis.h >+@@ -611,6 +615,10 @@ extern nis_error * nis_rmdir_3_svc (nis >+ extern nis_error * nis_updkeys_3 (nis_name *, CLIENT *) __THROW; >+ extern nis_error * nis_updkeys_3_svc (nis_name *, struct svc_req *) __THROW; >+ >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* ! _RPCSVC_NIS_H */ >+--- ./tirpc/rpcsvc/nislib.h.orig 2014-11-28 09:16:53.999289976 +0000 >++++ ./tirpc/rpcsvc/nislib.h 2014-11-28 09:16:54.000289976 +0000 >+@@ -23,7 +23,11 @@ >+ >+ #include <features.h> >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ >+ typedef const char *const_nis_name; >+ >+@@ -283,6 +287,10 @@ extern nis_error __nisfind_server (const >+ >+ #endif >+ >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* __RPCSVC_NISLIB_H__ */ >+--- ./tirpc/netconfig.h.orig 2014-11-28 09:16:54.003289976 +0000 >++++ ./tirpc/netconfig.h 2014-11-28 09:16:54.003289976 +0000 >+@@ -74,7 +74,11 @@ typedef struct { >+ #define NC_UDP "udp" >+ #define NC_ICMP "icmp" >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ >+ extern void *setnetconfig (void); >+ extern struct netconfig *getnetconfig (void *); >+@@ -89,6 +93,10 @@ extern int endnetpath (void *); >+ extern void nc_perror (const char *); >+ extern char *nc_sperror (void); >+ >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* _NETCONFIG_H_ */ >+--- ./src/rpc_com.h.orig 2014-11-28 09:16:53.975289976 +0000 >++++ ./src/rpc_com.h 2014-11-28 09:16:53.975289976 +0000 >+@@ -56,7 +56,11 @@ >+ #define __RPC_GETXID(now) ((u_int32_t)getpid() ^ (u_int32_t)(now)->tv_sec ^ \ >+ (u_int32_t)(now)->tv_usec) >+ >++#ifdef __GLIBC__ >+ __BEGIN_DECLS >++#elif defined(__cplusplus) >++extern "C" { >++#endif >+ extern u_int __rpc_get_a_size(int); >+ extern int __rpc_dtbsize(void); >+ extern struct netconfig * __rpcgettp(int); >+@@ -92,6 +96,10 @@ void __xprt_set_raddr(SVCXPRT *, const s >+ SVCXPRT **__svc_xports; >+ int __svc_maxrec; >+ >++#ifdef __GLIBC__ >+ __END_DECLS >++#elif defined(__cplusplus) >++} >++#endif >+ >+ #endif /* _TIRPC_RPCCOM_H */ >diff --git a/net-libs/libtirpc/files/0005-fix_remaining_issues.patch b/net-libs/libtirpc/files/0005-fix_remaining_issues.patch >new file mode 100644 >index 0000000..538e79e >--- /dev/null >+++ b/net-libs/libtirpc/files/0005-fix_remaining_issues.patch >@@ -0,0 +1,14 @@ >+--- ./tirpc/rpc/rpcent.h 2014-11-21 21:33:50.421928818 +0000 >++++ ./tirpc/rpc/rpcent.h 2014-11-21 21:35:05.140928818 +0000 >+@@ -64,6 +64,10 @@ extern struct rpcent *getrpcbynumber(int >+ extern struct rpcent *getrpcent(void); >+ #endif >+ >++#ifndef __GLIBC__ >++#define __THROW >++#endif >++ >+ extern void setrpcent(int) __THROW; >+ extern void endrpcent(void) __THROW; >+ #ifdef __GLIBC__ >+ >diff --git a/net-libs/libtirpc/files/0006-fix_queue_h_include.patch b/net-libs/libtirpc/files/0006-fix_queue_h_include.patch >new file mode 100644 >index 0000000..9db410c >--- /dev/null >+++ b/net-libs/libtirpc/files/0006-fix_queue_h_include.patch >@@ -0,0 +1,44 @@ >+--- src/clnt_bcast.c.orig 2014-11-28 09:31:22.462289976 +0000 >++++ src/clnt_bcast.c 2014-11-28 09:34:06.588289976 +0000 >+@@ -43,8 +43,41 @@ >+ */ >+ #include <sys/socket.h> >+ #include <sys/types.h> >++#ifdef __GLIBC__ >+ #include <sys/queue.h> >++#else >++/* >++ * * Tail queue definitions. >++ * */ >++#define _TAILQ_HEAD(name, type, qual) \ >++struct name { \ >++ qual type *tqh_first; /* first element */ \ >++ qual type *qual *tqh_last; /* addr of last next element */ \ >++} >++#define TAILQ_HEAD(name, type) _TAILQ_HEAD(name, struct type,) >+ >++#define _TAILQ_ENTRY(type, qual) \ >++struct { \ >++ qual type *tqe_next; /* next element */ \ >++ qual type *qual *tqe_prev; /* address of previous next element */\ >++} >++#define TAILQ_ENTRY(type) _TAILQ_ENTRY(struct type,) >++/* >++ * * Tail queue functions. >++ * */ >++#define TAILQ_INIT(head) do { \ >++ (head)->tqh_first = NULL; \ >++ (head)->tqh_last = &(head)->tqh_first; \ >++} while (/*CONSTCOND*/0) >++ >++#define TAILQ_INSERT_TAIL(head, elm, field) do { \ >++ (elm)->field.tqe_next = NULL; \ >++ (elm)->field.tqe_prev = (head)->tqh_last; \ >++ *(head)->tqh_last = (elm); \ >++ (head)->tqh_last = &(elm)->field.tqe_next; \ >++} while (/*CONSTCOND*/0) >++ >++#endif >+ #include <net/if.h> >+ #include <netinet/in.h> >+ #include <ifaddrs.h> >diff --git a/net-libs/libtirpc/files/0007-no-des.patch b/net-libs/libtirpc/files/0007-no-des.patch >new file mode 100644 >index 0000000..4347261 >--- /dev/null >+++ b/net-libs/libtirpc/files/0007-no-des.patch >@@ -0,0 +1,29 @@ >+--- libtirpc-0.2.5.orig/src/Makefile.am >++++ libtirpc-0.2.5/src/Makefile.am >+@@ -51,7 +51,7 @@ >+ rpc_callmsg.c rpc_generic.c rpc_soc.c rpcb_clnt.c rpcb_prot.c \ >+ rpcb_st_xdr.c svc.c svc_auth.c svc_dg.c svc_auth_unix.c svc_auth_none.c \ >+ svc_generic.c svc_raw.c svc_run.c svc_simple.c svc_vc.c getpeereid.c \ >+- auth_time.c auth_des.c authdes_prot.c debug.c >++ auth_time.c debug.c >+ >+ ## XDR >+ libtirpc_la_SOURCES += xdr.c xdr_rec.c xdr_array.c xdr_float.c xdr_mem.c xdr_reference.c xdr_stdio.c >+--- libtirpc-0.2.5.orig/src/rpc_soc.c >++++ libtirpc-0.2.5/src/rpc_soc.c >+@@ -520,6 +520,7 @@ >+ (resultproc_t) rpc_wrap_bcast, "udp"); >+ } >+ >++#if 0 >+ /* >+ * Create the client des authentication object. Obsoleted by >+ * authdes_seccreate(). >+@@ -551,6 +552,7 @@ >+ dummy = authdes_seccreate(servername, window, NULL, ckey); >+ return (dummy); >+ } >++#endif >+ >+ /* >+ * Create a client handle for a unix connection. Obsoleted by clnt_vc_create() >diff --git a/net-libs/libtirpc/files/libtirpc-0.2.1-fortify.patch b/net-libs/libtirpc/files/libtirpc-0.2.1-fortify.patch >new file mode 100644 >index 0000000..7375bf8 >--- /dev/null >+++ b/net-libs/libtirpc/files/libtirpc-0.2.1-fortify.patch >@@ -0,0 +1,18 @@ >+Index: libtirpc-0.2.1/src/getrpcport.c >+=================================================================== >+--- libtirpc-0.2.1.orig/src/getrpcport.c >++++ libtirpc-0.2.1/src/getrpcport.c >+@@ -54,11 +54,11 @@ getrpcport(host, prognum, versnum, proto >+ >+ if ((hp = gethostbyname(host)) == NULL) >+ return (0); >++ if (hp->h_length != sizeof(addr.sin_addr.s_addr)) >++ return (0); >+ memset(&addr, 0, sizeof(addr)); >+ addr.sin_family = AF_INET; >+ addr.sin_port = 0; >+- if (hp->h_length > sizeof(addr)) >+- hp->h_length = sizeof(addr); >+ memcpy(&addr.sin_addr.s_addr, hp->h_addr, (size_t)hp->h_length); >+ /* Inconsistent interfaces need casts! :-( */ >+ return (pmap_getport(&addr, (u_long)prognum, (u_long)versnum, >diff --git a/net-libs/libtirpc/files/libtirpc-0.2.2-rpc-des-prot.patch b/net-libs/libtirpc/files/libtirpc-0.2.2-rpc-des-prot.patch >new file mode 100644 >index 0000000..c5de6da >--- /dev/null >+++ b/net-libs/libtirpc/files/libtirpc-0.2.2-rpc-des-prot.patch >@@ -0,0 +1,36 @@ >+From f2f43212b33dea42635061c82645287454a70107 Mon Sep 17 00:00:00 2001 >+From: Mike Frysinger <vapier@gentoo.org> >+Date: Sat, 11 Jun 2011 15:21:55 -0400 >+Subject: [PATCH] add multiple inclusion protection to rpc/des.h >+ >+If you try to include this file multiple times, you get a build failure >+due to redefinitions of enums and such. >+ >+Signed-off-by: Mike Frysinger <vapier@gentoo.org> >+--- >+ tirpc/rpc/des.h | 5 +++++ >+ 1 files changed, 5 insertions(+), 0 deletions(-) >+ >+diff --git a/tirpc/rpc/des.h b/tirpc/rpc/des.h >+index e3d6897..d2881ad 100644 >+--- a/tirpc/rpc/des.h >++++ b/tirpc/rpc/des.h >+@@ -33,6 +33,9 @@ >+ * Copyright (c) 1986 by Sun Microsystems, Inc. >+ */ >+ >++#ifndef _RPC_DES_H_ >++#define _RPC_DES_H_ >++ >+ #define DES_MAXLEN 65536 /* maximum # of bytes to encrypt */ >+ #define DES_QUICKLEN 16 /* maximum # of bytes to encrypt quickly */ >+ >+@@ -80,3 +83,5 @@ struct desparams { >+ * Software DES. >+ */ >+ extern int _des_crypt( char *, int, struct desparams * ); >++ >++#endif >+-- >+1.7.5.3 >+ >diff --git a/net-libs/libtirpc/files/libtirpc-0.2.5-stdarg.patch b/net-libs/libtirpc/files/libtirpc-0.2.5-stdarg.patch >new file mode 100644 >index 0000000..8006de3 >--- /dev/null >+++ b/net-libs/libtirpc/files/libtirpc-0.2.5-stdarg.patch >@@ -0,0 +1,29 @@ >+From d26607bade0893fe8652e1a0983f9fae59c64649 Mon Sep 17 00:00:00 2001 >+From: Mike Frysinger <vapier@gentoo.org> >+Date: Tue, 12 Aug 2014 03:11:41 -0400 >+Subject: [PATCH libtirpc] include stdarg.h when used >+ >+The debug.h header uses va_list but doesn't include stdarg.h which >+can lead to random build failures. >+ >+Signed-off-by: Mike Frysinger <vapier@gentoo.org> >+--- >+ src/debug.h | 2 ++ >+ 1 file changed, 2 insertions(+) >+ >+diff --git a/src/debug.h b/src/debug.h >+index afc8d57..c971ac3 100644 >+--- a/src/debug.h >++++ b/src/debug.h >+@@ -21,6 +21,8 @@ >+ >+ #ifndef _DEBUG_H >+ #define _DEBUG_H >++ >++#include <stdarg.h> >+ #include <syslog.h> >+ >+ extern int libtirpc_debug_level; >+-- >+2.0.0 >+ >diff --git a/net-libs/libtirpc/libtirpc-0.2.5-r99.ebuild b/net-libs/libtirpc/libtirpc-0.2.5-r99.ebuild >new file mode 100644 >index 0000000..01048ab >--- /dev/null >+++ b/net-libs/libtirpc/libtirpc-0.2.5-r99.ebuild >@@ -0,0 +1,74 @@ >+# Copyright 1999-2014 Gentoo Foundation >+# Distributed under the terms of the GNU General Public License v2 >+# $Header: /var/cvsroot/gentoo-x86/net-libs/libtirpc/libtirpc-0.2.5.ebuild,v 1.4 2014/12/30 18:09:41 maekke Exp $ >+ >+EAPI="4" >+ >+inherit multilib-minimal toolchain-funcs autotools >+ >+DESCRIPTION="Transport Independent RPC library (SunRPC replacement)" >+HOMEPAGE="http://libtirpc.sourceforge.net/" >+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2 >+ mirror://gentoo/${PN}-glibc-nfs.tar.xz" >+ >+LICENSE="GPL-2" >+SLOT="0" >+KEYWORDS="~amd64 ~arm ~mips ~ppc ~x86" >+IUSE="ipv6 kerberos static-libs" >+ >+RDEPEND="kerberos? ( >=virtual/krb5-0-r1[${MULTILIB_USEDEP}] )" >+DEPEND="${RDEPEND} >+ app-arch/xz-utils >+ >=virtual/pkgconfig-0-r1[${MULTILIB_USEDEP}]" >+RDEPEND="${RDEPEND} >+ abi_x86_32? ( >+ !<=app-emulation/emul-linux-x86-baselibs-20140508-r7 >+ !app-emulation/emul-linux-x86-baselibs[-abi_x86_32(-)] >+ )" >+ >+src_unpack() { >+ unpack ${A} >+ cp -r tirpc "${S}"/ || die >+} >+ >+src_prepare() { >+ epatch "${FILESDIR}"/${P}-stdarg.patch >+ epatch "${FILESDIR}"/0001-Provide-getrpcbynumber-and-getrpcbyname-if-those-are.patch >+ epatch "${FILESDIR}"/0002-Misc-header-fixes.patch >+ epatch "${FILESDIR}"/0003-fix_cdefs_h_include.patch >+ epatch "${FILESDIR}"/0004-fix_DECLS.patch >+ epatch "${FILESDIR}"/0005-fix_remaining_issues.patch >+ epatch "${FILESDIR}"/0006-fix_queue_h_include.patch >+ epatch "${FILESDIR}"/0007-no-des.patch >+ eautoconf >+ eautoreconf >+} >+ >+multilib_src_configure() { >+ ECONF_SOURCE=${S} \ >+ econf \ >+ $(use_enable ipv6) \ >+ $(use_enable kerberos gssapi) \ >+ $(use_enable static-libs static) >+} >+ >+multilib_src_install() { >+ default >+ >+ # libtirpc replaces rpc support in glibc, so we need it in / >+ multilib_is_native_abi && gen_usr_ldscript -a tirpc >+} >+ >+multilib_src_install_all() { >+ einstalldocs >+ >+ insinto /etc >+ doins doc/netconfig >+ >+ insinto /usr/include/tirpc >+ doins -r "${WORKDIR}"/tirpc/* >+ >+ # makes sure that the linking order for nfs-utils is proper, as >+ # libtool would inject a libgssglue dependency in the list. >+ use static-libs || prune_libtool_files >+} >diff --git a/net-libs/libtirpc/metadata.xml b/net-libs/libtirpc/metadata.xml >new file mode 100644 >index 0000000..ca66751 >--- /dev/null >+++ b/net-libs/libtirpc/metadata.xml >@@ -0,0 +1,5 @@ >+<?xml version="1.0" encoding="UTF-8"?> >+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> >+<pkgmetadata> >+<herd>net-fs</herd> >+</pkgmetadata> >-- >2.0.5 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 530080
:
390028
|
390030
|
390032
|
390034
|
390460
|
390462
|
390464
|
390466
|
390468
|
390470
|
390590
|
390592
|
390594
|
390596
|
390598
|
390600
|
390602
|
390604
| 393610