diff options
Diffstat (limited to 'sys-libs/libcap')
-rw-r--r-- | sys-libs/libcap/Manifest | 20 | ||||
-rw-r--r-- | sys-libs/libcap/files/libcap-2.25-ignore-RAISE_SETFCAP-install-failures.patch | 9 | ||||
-rw-r--r-- | sys-libs/libcap/files/libcap-2.38-no_perl.patch | 9 | ||||
-rw-r--r-- | sys-libs/libcap/files/libcap-2.48-build-system-fixes.patch | 24 | ||||
-rw-r--r-- | sys-libs/libcap/files/libcap-2.57-parallel-make.patch | 29 | ||||
-rw-r--r-- | sys-libs/libcap/files/libcap-2.61-Wformat.patch | 25 | ||||
-rw-r--r-- | sys-libs/libcap/files/libcap-2.61-ignore-RAISE_SETFCAP-install-failures.patch | 24 | ||||
-rw-r--r-- | sys-libs/libcap/files/libcap-2.61-no_perl.patch | 57 | ||||
-rw-r--r-- | sys-libs/libcap/libcap-2.57.ebuild | 90 | ||||
-rw-r--r-- | sys-libs/libcap/libcap-2.58.ebuild | 88 | ||||
-rw-r--r-- | sys-libs/libcap/libcap-2.59.ebuild | 88 | ||||
-rw-r--r-- | sys-libs/libcap/libcap-2.61.ebuild (renamed from sys-libs/libcap/libcap-2.60.ebuild) | 9 |
12 files changed, 120 insertions, 352 deletions
diff --git a/sys-libs/libcap/Manifest b/sys-libs/libcap/Manifest index c80ac99e3db4..e4b1322543a5 100644 --- a/sys-libs/libcap/Manifest +++ b/sys-libs/libcap/Manifest @@ -1,16 +1,12 @@ AUX libcap-2.21-include.patch 218 BLAKE2B 536be33e749bc818efb29e3a7a010029025520c4694178aa1d85bf0c48abfca4c77f940b4fbb9bd08464edc31af657960fc41cab71d112ebf3573d1aa1f23148 SHA512 637f5dc2d7ead44a19a57db436ddf7e8afa1b368c72e5520a1ac77633c20b0f9a2af9defdafed1edb7209474798d1bcd236c712a160b5c6920d8864411baefed -AUX libcap-2.25-ignore-RAISE_SETFCAP-install-failures.patch 988 BLAKE2B 63417032b843ff7cb704c9880cfca4db5083d05d479c71dd12925d729f22a4900c2ae277a20399d58830eaca969842d587a2ae0a646809d6b659a75d13678312 SHA512 ba573ce68858c1370f3d25ad03678a534e6f3052076694d09e795d1febf2f3d76a6a170658b71d9e31105521fd5d22dd72095585a5402286dba424937064b389 -AUX libcap-2.38-no_perl.patch 3049 BLAKE2B 77fdcda75b273fd69695161d48f37fda40375f5f36acdb31e9f9e5b7585e6933733586c6ad96673efb79a6657dbbffd4431612ed723905e9f4d595a9dd8c49c4 SHA512 f3938a8a78407639bfdda4d9c4b4096025f956430f9efbce438689aabbea74915c55c6afbd45a7af4ecc0c437ee72e9aa8335da52d3237c928702e62824e537a -AUX libcap-2.48-build-system-fixes.patch 6274 BLAKE2B 4c81eb50b0a682ca9df03145a53e884589e0961e1b754b522f40d48fca60fe983ae93349d256e62977bf28c99c8c25763d05aa8483aebfc436664756a220d70a SHA512 5b88a5c5ea14d2270ed4018249ceb32b0c91db03ed18a6989cc44250da91887385dc3f37087f716771ddbaa90c7e3d733a64063507465eb354252d9f64b85f80 -AUX libcap-2.57-parallel-make.patch 1103 BLAKE2B f5c1517577d7c34ed8a4b9fcc8527e93a5b6301b3c2bbcfda21f3caa4bd3c22e6d524ea19f93c645f4f93153a71f93c132c97bac90594d4abbb3bb629d175daf SHA512 06e2d5d3bc757760b3bddedaec88373a7aef7d9052003bac46fe491d2e356247f0f1b199dc1ea11cfd368a5c047e8621e8f0cf8a1d82407deeee2ebde60f67a5 +AUX libcap-2.25-ignore-RAISE_SETFCAP-install-failures.patch 827 BLAKE2B 0ed207a478c50dd9f3590cd36ab4b37e6c41ddb266709b1bf012cf11dec0c2f8e3f0cbb0918f3be72831321aa8953f936a2706f1038c4ce5287c73dc83887e43 SHA512 d0302604e28ed2354214d315a812422355f98cd69d2b3089dd20cef1e243e4ac433ae47026b57a8f6db66572693ce2523af6cb2a8e4715af266442de7dd33e9b +AUX libcap-2.38-no_perl.patch 2856 BLAKE2B f10169dab10a60973a5fbbbe55a14342a7a582dd79a40a0ca33f3cc3cbd5c695ef7cfcce28d6448df8875903f53e265b85c6738d8fe8800bfa1e596748deecbe SHA512 6b3fdebe763b7f7300c4e6c16140f95c490e8fdd9a8d7b6ddf250299a32dcbd78b3a3936cf8bbeb381cd305966b37f381a26965e3ff91944ebdac22e810ec49f +AUX libcap-2.48-build-system-fixes.patch 5591 BLAKE2B 20fce03037ffbd59e3000f7c757d698c412d5709d2a575b5b59197b263097a445684509b2d0b8d77ea0e3e39f7660147e676a12b8e56fc1e2204f8c8a8da1fe7 SHA512 a7e22630b2690b039f9b257dc148868ee9c5b397bab2bd9d6591ab57929be7fb9c75db2a51f08815a618756743299b08537d93eb7507a984eb7bcf086e82ff10 +AUX libcap-2.61-Wformat.patch 723 BLAKE2B c337561e8505a2d6afac05aa9f4b628ac3305c0fe5963d5b8ffd4767e5f8e4e5e01490801b91c2bc6bf676f9b86f95d600def2e3e02ebcee6e9a568e17cbd126 SHA512 810cc4249c0b64f5e7aa5308dfd0d491ace50b02a55b40696b0136a71213e3c600a853a68940411c3cb64a63af4b9c65f839803533ed29e475bfded2b571d51d +AUX libcap-2.61-ignore-RAISE_SETFCAP-install-failures.patch 813 BLAKE2B 0f2fffffab12d4c1cdd939aae5f8cb0e73073feec92af9f4bf44005a545c991d9649307370061a5dcbaa30285761276549da9253c891fc5ea0108f552c04cd8e SHA512 1ed308be3e66bb315584aa0bf7915893b168850fe9ef7c5035214abc6a2eea5371aaa7f14c2f2790e60c4024e7bb0c08eabb1b8ed63eb22113644d95f057b533 +AUX libcap-2.61-no_perl.patch 2469 BLAKE2B d059cb89175b413f5ddabc2c30e4c8f37226cbd589b936ba0cd94f9529d46abffa2679125e9c8e8f939ef3c7c0e68a1b3b16685ce5b386d82176862a05428bf6 SHA512 0706d6b5ee2d93fe58ae53c9850622b21531af682d4774ecaccb04bab11a45393c46a5c9c64ba3d2df1cf2b25152c72145f66951a9a16ac0452700b503f96d86 DIST libcap-2.49.tar.xz 139568 BLAKE2B 5746dcdf2a737e747450bd50a701ee8543277b17b7fbf1304b79f707a088ea74dc6dc79c61ff89b55b718a460a7b0814f960f44d07944a97b832b78f4e14e07f SHA512 2934a2ded1370edeb9603dbf43d8ca23a2eb5d67efc5cec5d4ba96c707a8db2702da8aa9be0cb86c5ff100d37ec96115c7777a7566ad0ab2e0b4a288bbe357d0 -DIST libcap-2.57.tar.xz 167740 BLAKE2B e0c004f3d11caf824d907315e6102707bb34c0ef3e9d430f23c191d711f073267ef6dc44463e2ce8041b8d13658b0c20560f7f3c6387f770ff9e66b81ff9f5d3 SHA512 5c70b3c6a1248ca0de92538614f0d0d516d72f6f25b135c92738c377b67533662e6fd6b0b61cb051ec99f406387d3334fcc7ddb54789626e4c387bcf46ebffbf -DIST libcap-2.58.tar.xz 168520 BLAKE2B 9f160c08e7e8bcb9eb49ab6a7a0805145461613a946ccfebeadc269b26331eadc9f467437b2f5b022e9a545b034ea4fd8fed4d5893e84d9a48dd85318810b974 SHA512 092e45f82113293e1c2db7e51dca7298496c2a3af08eb41107e8c2b4798c25d3c9059e152181dc048b232fe0e59c4c3beaa158da2e5798cd6e1013d85226a9cf -DIST libcap-2.59.tar.xz 168404 BLAKE2B 5db562b389f2c4034b5fa840a14f7fd7ada49470fea8d13828b2c302a7d768831a6215593d21938b8e1d5bd65fa0581628809526fa5f6091ca4eac5e884cd38c SHA512 296c11259e1b4d577b3527ab5e2160be3f94a2bee7d63d1b7feadc603f7e160b72f8c8ede34dec269f5eb7595304ff290693803be778bdbbe088de0e99a33812 -DIST libcap-2.60.tar.xz 170744 BLAKE2B 858b5133a5cb2f3b30dab569a6c9f2097034318c90419fa2372e0b28c891160f5e84b54b302b2d98664df8f7c44df78eb3cb4e47b328cecd4c27e7ab223045ae SHA512 f2ff0d81df7251c05decda706ccc6463ce58df6a3c542fe479328dce5416f77aa5c6a09a1ab05a1d1a3638e6dae5c0e546aaa4824843a570700a8927fb7f73e6 +DIST libcap-2.61.tar.xz 173892 BLAKE2B 50874d3510ab2476aaceb775314d98744736aacd7364a23827756caa160c101e8bc890b7c33b5e19df8b30bb6b3b1c2be323e4b6a963f97e9ee557e86b4f13a0 SHA512 40096bf511d1c45e36f5d7f24e49c709528f3f01fcadd47b6ac40a7e8d5f1705b29b4cc56356b030639f67d0641b9f4e7c19449c3c7f4f77a4070c35745b465c EBUILD libcap-2.49-r1.ebuild 2127 BLAKE2B d77712422b1cb13b04b1a18e573c20151b03098a9effaee4a62b51f4035eac2f3dcc2760f6050d05220dca63edbd978df79299e6be4c885a73ec7a079d1cd558 SHA512 fb01c7f3c68d3fa55221bc0602c21ddb399121f97a0a3c9ef5788bbecb3912cc9f9924bd0339e27acc3103d3a1e110b4029f99c27a7232fd83229075383d898b -EBUILD libcap-2.57.ebuild 2218 BLAKE2B 31b59f3288097cbad2db73d8a08f6c92dd20e8f3db24ca3a70e38d6d8d07294833eb6773db1822b508c11fc7af47f30b422f0c578dd7f4d029e5af278e77cfd9 SHA512 ebf697457e90c80c89f67b0d1087856edb50a5ec7dc2cc45d13ad3e83c060bd71b519f88c02e70d2207d24e85941942663f370fe5ce488364cffa1c7e8b5f7b3 -EBUILD libcap-2.58.ebuild 2136 BLAKE2B 01dfe09c3089be3dc63da9d5c2ab8a1804979bb2a901d229cdd1f4722050307dc020f6745609bebc2e3d331065fa0ab06bcff2ce0b53588276eb3087f8afacb2 SHA512 75de17b063652f6c0788c26d19589c1790d5e713c47558f1e6ff28e4e7adfc6a66683be2fbc8cf6250ebc3e8670e4bcbee8f8f1d692846550b3aeb35334dbac9 -EBUILD libcap-2.59.ebuild 2136 BLAKE2B 01dfe09c3089be3dc63da9d5c2ab8a1804979bb2a901d229cdd1f4722050307dc020f6745609bebc2e3d331065fa0ab06bcff2ce0b53588276eb3087f8afacb2 SHA512 75de17b063652f6c0788c26d19589c1790d5e713c47558f1e6ff28e4e7adfc6a66683be2fbc8cf6250ebc3e8670e4bcbee8f8f1d692846550b3aeb35334dbac9 -EBUILD libcap-2.60.ebuild 2136 BLAKE2B 01dfe09c3089be3dc63da9d5c2ab8a1804979bb2a901d229cdd1f4722050307dc020f6745609bebc2e3d331065fa0ab06bcff2ce0b53588276eb3087f8afacb2 SHA512 75de17b063652f6c0788c26d19589c1790d5e713c47558f1e6ff28e4e7adfc6a66683be2fbc8cf6250ebc3e8670e4bcbee8f8f1d692846550b3aeb35334dbac9 +EBUILD libcap-2.61.ebuild 2198 BLAKE2B 70773f85a588a95c37ca9338fd89d1eb573372971b97383b829d4fd67305b9ffb188462c1213ea996b01a305bfed4b653c31f1d575974dd5b0ef24b2e8d824c0 SHA512 d3ed87ac4b12733546fda55113c5e50409856e7d8373a7f55813852c411509d880d819f01bc5a273e94ef1187b01f3883c68d4366c8ed900cdd7c732668ac4a3 MISC metadata.xml 438 BLAKE2B b5260cc84a3fe6b992bb6218846c738af296522d7a467337c05a6240fd07fc9d6cece779bd9fcf24a11486a70874e17acae8182647d307a31cf43e1c19c3a2d3 SHA512 fa3713dcf6b7bb2ea6d4c2fdefc05e92ae345c76a6187ebcb40dab8c4ce0148650a8301f236efcb8cf53fff25730977a385578dbaa160b800159c6d6abbf37a9 diff --git a/sys-libs/libcap/files/libcap-2.25-ignore-RAISE_SETFCAP-install-failures.patch b/sys-libs/libcap/files/libcap-2.25-ignore-RAISE_SETFCAP-install-failures.patch index 0f737361a4d1..e5455cd1ebb6 100644 --- a/sys-libs/libcap/files/libcap-2.25-ignore-RAISE_SETFCAP-install-failures.patch +++ b/sys-libs/libcap/files/libcap-2.25-ignore-RAISE_SETFCAP-install-failures.patch @@ -11,12 +11,6 @@ Signed-off-by: Mike Frysinger <vapier@gentoo.org> Forward ported from libcap-2.20 to libcap-2.25 Signed-off-by: Lars Wendler <polynomial-c@gentoo.org> ---- - progs/Makefile | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/progs/Makefile b/progs/Makefile -index c094a24..4a6db38 100644 --- a/progs/Makefile +++ b/progs/Makefile @@ -27,7 +27,7 @@ install: all @@ -28,6 +22,3 @@ index c094a24..4a6db38 100644 endif clean: --- -2.7.1 - diff --git a/sys-libs/libcap/files/libcap-2.38-no_perl.patch b/sys-libs/libcap/files/libcap-2.38-no_perl.patch index f3e0c468c869..9104484d5770 100644 --- a/sys-libs/libcap/files/libcap-2.38-no_perl.patch +++ b/sys-libs/libcap/files/libcap-2.38-no_perl.patch @@ -14,12 +14,6 @@ Forward ported from libcap-2.26 to libcap-2.28 Forward ported from libcap-2.28 to libcap-2.38 Signed-off-by: Lars Wendler <polynomial-c@gentoo.org> ---- - libcap/Makefile | 26 +++++++++++++++++++------- - 1 file changed, 19 insertions(+), 7 deletions(-) - -diff --git a/libcap/Makefile b/libcap/Makefile -index 3d6463d..df2526c 100644 --- a/libcap/Makefile +++ b/libcap/Makefile @@ -22,6 +22,8 @@ MAJLIBNAME=$(LIBNAME).$(VERSION) @@ -66,6 +60,3 @@ index 3d6463d..df2526c 100644 $(STACAPLIBNAME): $(CAPOBJS) $(AR) rcs $@ $^ --- -2.27.0 - diff --git a/sys-libs/libcap/files/libcap-2.48-build-system-fixes.patch b/sys-libs/libcap/files/libcap-2.48-build-system-fixes.patch index a672ecedaca6..b3986e19546c 100644 --- a/sys-libs/libcap/files/libcap-2.48-build-system-fixes.patch +++ b/sys-libs/libcap/files/libcap-2.48-build-system-fixes.patch @@ -27,17 +27,6 @@ Forward ported from libcap-2.44 to libcap-2.45 Forward ported from libcap-2.45 to libcap-2.48 Signed-off-by: Lars Wendler <polynomial-c@gentoo.org> ---- - Make.Rules | 10 ++++++---- - Makefile | 1 - - libcap/Makefile | 7 ++++--- - pam_cap/Makefile | 8 +++++--- - progs/Makefile | 2 +- - tests/Makefile | 6 ++++-- - 6 files changed, 20 insertions(+), 14 deletions(-) - -diff --git a/Make.Rules b/Make.Rules -index ded9014..07b716f 100644 --- a/Make.Rules +++ b/Make.Rules @@ -52,7 +52,6 @@ GOMAJOR=0 @@ -73,8 +62,6 @@ index ded9014..07b716f 100644 INDENT := $(shell if [ -n "$$(which indent 2>/dev/null)" ]; then echo "| indent -kr" ; fi) # SHARED tracks whether or not the SHARED libraries (libcap.so, -diff --git a/Makefile b/Makefile -index 7150b9b..9dff1e9 100644 --- a/Makefile +++ b/Makefile @@ -17,7 +17,6 @@ ifeq ($(GOLANG),yes) @@ -85,8 +72,6 @@ index 7150b9b..9dff1e9 100644 $(MAKE) -C progs $@ $(MAKE) -C doc $@ $(MAKE) -C kdebug $@ -diff --git a/libcap/Makefile b/libcap/Makefile -index 9563d88..4b42f01 100644 --- a/libcap/Makefile +++ b/libcap/Makefile @@ -25,6 +25,7 @@ MINCAPLIBNAME=$(MAJCAPLIBNAME).$(MINOR) @@ -119,8 +104,6 @@ index 9563d88..4b42f01 100644 cap_test: cap_test.c libcap.h $(CC) $(CFLAGS) $(IPATH) $< -o $@ -diff --git a/pam_cap/Makefile b/pam_cap/Makefile -index 56604fd..2da4674 100644 --- a/pam_cap/Makefile +++ b/pam_cap/Makefile @@ -3,6 +3,8 @@ @@ -152,8 +135,6 @@ index 56604fd..2da4674 100644 test: pam_cap.so make testlink -diff --git a/progs/Makefile b/progs/Makefile -index 1d7fc7a..64dbe86 100644 --- a/progs/Makefile +++ b/progs/Makefile @@ -28,7 +28,7 @@ $(BUILD): %: %.o $(DEPS) @@ -165,8 +146,6 @@ index 1d7fc7a..64dbe86 100644 install: all mkdir -p -m 0755 $(FAKEROOT)$(SBINDIR) -diff --git a/tests/Makefile b/tests/Makefile -index 1e7039d..5874624 100644 --- a/tests/Makefile +++ b/tests/Makefile @@ -13,6 +13,8 @@ ifeq ($(PTHREADS),yes) @@ -194,6 +173,3 @@ index 1e7039d..5874624 100644 # privileged run_libcap_launch_test: libcap_launch_test noop ../progs/tcapsh-static --- -2.30.0 - diff --git a/sys-libs/libcap/files/libcap-2.57-parallel-make.patch b/sys-libs/libcap/files/libcap-2.57-parallel-make.patch deleted file mode 100644 index 612044bcfb0d..000000000000 --- a/sys-libs/libcap/files/libcap-2.57-parallel-make.patch +++ /dev/null @@ -1,29 +0,0 @@ -https://git.kernel.org/pub/scm/libs/libcap/libcap.git/patch/?id=893c134ca5cd6fc33ac19d8dbb9d985067d2e66b - -From: "Andrew G. Morgan" <morgan@kernel.org> -Date: Fri, 10 Sep 2021 16:11:57 -0700 -Subject: Another missing dependency for make -j13 - -One more missing dependency for pam_cap.so building. - -Signed-off-by: Andrew G. Morgan <morgan@kernel.org> ---- a/pam_cap/Makefile -+++ b/pam_cap/Makefile -@@ -19,7 +19,11 @@ install: all - execable.o: execable.c ../libcap/execable.h ../libcap/loader.txt - $(CC) $(CFLAGS) $(CPPFLAGS) -DLIBCAP_VERSION=\"libcap-$(VERSION).$(MINOR)\" -DSHARED_LOADER=\"$(shell cat ../libcap/loader.txt)\" -c execable.c -o $@ - --pam_cap.so: pam_cap.o execable.o pam_cap_linkopts -+LIBCAP: -+ $(MAKE) -C ../libcap all -+ touch $@ -+ -+pam_cap.so: pam_cap.o execable.o pam_cap_linkopts LIBCAP - cat pam_cap_linkopts | xargs -e $(LD) $(LDFLAGS) -o $@ pam_cap.o execable.o $(LIBCAPLIB) - - # Some distributions force link everything at compile time, and don't -@@ -83,3 +87,4 @@ sudotest: test_pam_cap - - clean: - rm -f *.o *.so testlink lazylink.so test_pam_cap pam_cap_linkopts *~ -+ rm -f LIBCAP diff --git a/sys-libs/libcap/files/libcap-2.61-Wformat.patch b/sys-libs/libcap/files/libcap-2.61-Wformat.patch new file mode 100644 index 000000000000..e0046de58770 --- /dev/null +++ b/sys-libs/libcap/files/libcap-2.61-Wformat.patch @@ -0,0 +1,25 @@ +From 9fd3e7ac5870f84c73ac777d9a14480227ad7f00 Mon Sep 17 00:00:00 2001 +From: David Seifert <soap@gentoo.org> +Date: Sun, 28 Nov 2021 14:14:42 +0100 +Subject: [PATCH] Fix `-Wformat` on 32-bit platforms + +--- + libcap/cap_test.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/libcap/cap_test.c b/libcap/cap_test.c +index b7fb2c5..39df261 100644 +--- a/libcap/cap_test.c ++++ b/libcap/cap_test.c +@@ -124,7 +124,7 @@ static int test_short_bits(void) + } + if (strlen(tmp) > __CAP_NAME_SIZE) { + printf("cap_to_text buffer size reservation needs fixing (%ld > %d)\n", +- strlen(tmp), __CAP_NAME_SIZE); ++ (long int)strlen(tmp), __CAP_NAME_SIZE); + result = -1; + } + free(tmp); +-- +2.34.1 + diff --git a/sys-libs/libcap/files/libcap-2.61-ignore-RAISE_SETFCAP-install-failures.patch b/sys-libs/libcap/files/libcap-2.61-ignore-RAISE_SETFCAP-install-failures.patch new file mode 100644 index 000000000000..25f853b2a982 --- /dev/null +++ b/sys-libs/libcap/files/libcap-2.61-ignore-RAISE_SETFCAP-install-failures.patch @@ -0,0 +1,24 @@ +From 8dfcdcfdcb9c462a05566aa8d3c6eca871f0ddbf Mon Sep 17 00:00:00 2001 +From: Mike Frysinger <vapier@gentoo.org> +Date: Wed, 10 Feb 2016 09:52:45 +0100 +Subject: [PATCH] ignore RAISE_SETFCAP install failures + +While the new RAISE_SETFCAP feature is nifty, its failure to run (often +due to the fs not supporting it) shouldn't impair the default install. + +Signed-off-by: Mike Frysinger <vapier@gentoo.org> + +Forward ported from libcap-2.20 to libcap-2.25 + +Signed-off-by: Lars Wendler <polynomial-c@gentoo.org> +--- a/progs/Makefile ++++ b/progs/Makefile +@@ -39,7 +39,7 @@ + install -m 0755 $$p $(FAKEROOT)$(SBINDIR) ; \ + done + ifeq ($(RAISE_SETFCAP),yes) +- $(FAKEROOT)$(SBINDIR)/setcap cap_setfcap=i $(FAKEROOT)$(SBINDIR)/setcap ++ -$(FAKEROOT)$(SBINDIR)/setcap cap_setfcap=i $(FAKEROOT)$(SBINDIR)/setcap + endif + + test: diff --git a/sys-libs/libcap/files/libcap-2.61-no_perl.patch b/sys-libs/libcap/files/libcap-2.61-no_perl.patch new file mode 100644 index 000000000000..3d42a4dc6135 --- /dev/null +++ b/sys-libs/libcap/files/libcap-2.61-no_perl.patch @@ -0,0 +1,57 @@ +From 3f76418eaf73896489129c529fac021e4f3a03c0 Mon Sep 17 00:00:00 2001 +From: Mike Frysinger <vapier@gentoo.org> +Date: Wed, 21 Nov 2018 11:00:54 +0100 +Subject: [PATCH] use awk/sed instead of perl for creating header files + +More systems should have awk/sed than perl. + +Signed-off-by: Mike Frysinger <vapier@gentoo.org> + +Forward ported from libcap-2.22 to libcap-2.26 +and incorporated the gperf-3.1 fix provided by Mike Gilbert +<floppym@gentoo.org> +Forward ported from libcap-2.26 to libcap-2.28 +Forward ported from libcap-2.28 to libcap-2.38 + +Signed-off-by: Lars Wendler <polynomial-c@gentoo.org> +--- a/libcap/Makefile ++++ b/libcap/Makefile +@@ -20,6 +20,8 @@ + + # Always build libcap sources this way: + CFLAGS += -fPIC ++AWK = awk ++SED = sed + + # The linker magic needed to build a dynamic library as independently + # executable +@@ -82,8 +84,18 @@ + ./_makenames > cap_names.h + + $(GPERF_OUTPUT): cap_names.list.h +- perl -e 'print "struct __cap_token_s { const char *name; int index; };\n%{\nconst struct __cap_token_s *__cap_lookup_name(const char *, size_t);\n%}\n%%\n"; while ($$l = <>) { $$l =~ s/[\{\"]//g; $$l =~ s/\}.*// ; print $$l; }' < $< | gperf --ignore-case --language=ANSI-C --readonly --null-strings --global-table --hash-function-name=__cap_hash_name --lookup-function-name="__cap_lookup_name" -c -t -m20 $(INDENT) > $@ +- sed -e 's/unsigned int len/size_t len/' -i $@ ++ (printf "%b" "struct __cap_token_s { const char *name; int index; };\n%%\n"; \ ++ $(SED) -e 's:["{}]::g' -e 's:,$$::' $<) | \ ++ gperf \ ++ --ignore-case \ ++ --language=ANSI-C \ ++ --includes \ ++ --readonly \ ++ --null-strings \ ++ --global-table \ ++ --hash-function-name=__cap_hash_name \ ++ --lookup-function-name="__cap_lookup_name" \ ++ -c -t -m20 $(INDENT) > $@ + + # Intention is that libcap keeps up with torvalds' tree, as reflected + # by this maintained version of the kernel header. libcap dynamically +@@ -92,7 +104,7 @@ + UAPI_HEADER := $(topdir)/libcap/include/uapi/linux/capability.h + cap_names.list.h: Makefile $(UAPI_HEADER) + @echo "=> making $@ from $(UAPI_HEADER)" +- perl -e 'while ($$l=<>) { if ($$l =~ /^\#define[ \t](CAP[_A-Z]+)[ \t]+([0-9]+)\s+$$/) { $$tok=$$1; $$val=$$2; $$tok =~ tr/A-Z/a-z/; print "{\"$$tok\",$$val},\n"; } }' $(UAPI_HEADER) | fgrep -v 0x > $@ ++ $(AWK) '($$0 ~ /^#define[[:space:]]+CAP[_A-Z]+[[:space:]]+[0-9]+[[:space:]]*$$/) { printf "{\"%s\",%s},\n", tolower($$2), $$3 }' $(UAPI_HEADER) > $@ + + $(STACAPLIBNAME): $(CAPOBJS) + $(AR) rcs $@ $^ diff --git a/sys-libs/libcap/libcap-2.57.ebuild b/sys-libs/libcap/libcap-2.57.ebuild deleted file mode 100644 index ca29aacc3bb7..000000000000 --- a/sys-libs/libcap/libcap-2.57.ebuild +++ /dev/null @@ -1,90 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -inherit multilib-minimal toolchain-funcs pam usr-ldscript - -DESCRIPTION="POSIX 1003.1e capabilities" -HOMEPAGE="https://sites.google.com/site/fullycapable/" -SRC_URI="https://www.kernel.org/pub/linux/libs/security/linux-privs/libcap2/${P}.tar.xz" - -# it's available under either of the licenses -LICENSE="|| ( GPL-2 BSD )" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux" -IUSE="pam static-libs tools" - -# While the build system optionally uses gperf, we don't DEPEND on it because -# the build automatically falls back when it's unavailable. #604802 -PDEPEND="pam? ( sys-libs/pam[${MULTILIB_USEDEP}] )" -DEPEND="${PDEPEND} - sys-kernel/linux-headers" -BDEPEND="tools? ( dev-lang/go )" - -PATCHES=( - # Backported patch, drop on > 2.57 - "${FILESDIR}"/${PN}-2.57-parallel-make.patch - "${FILESDIR}"/${PN}-2.38-no_perl.patch - "${FILESDIR}"/${PN}-2.25-ignore-RAISE_SETFCAP-install-failures.patch -) - -QA_FLAGS_IGNORED="sbin/captree" # go binaries don't use LDFLAGS - -src_prepare() { - default - multilib_copy_sources -} - -run_emake() { - local args=( - AR="$(tc-getAR)" - CC="$(tc-getCC)" - OBJCOPY="$(tc-getOBJCOPY)" - RANLIB="$(tc-getRANLIB)" - exec_prefix="${EPREFIX}" - lib_prefix="${EPREFIX}/usr" - lib="$(get_libdir)" - prefix="${EPREFIX}/usr" - PAM_CAP="$(usex pam yes no)" - DYNAMIC=yes - GOLANG="$(multilib_native_usex tools yes no)" - ) - emake "${args[@]}" "$@" -} - -src_configure() { - tc-export_build_env BUILD_CC - multilib-minimal_src_configure -} - -multilib_src_compile() { - run_emake -} - -multilib_src_test() { - run_emake test -} - -multilib_src_install() { - # no configure, needs explicit install line #444724#c3 - run_emake DESTDIR="${D}" install - - gen_usr_ldscript -a cap - gen_usr_ldscript -a psx - if ! use static-libs ; then - rm "${ED}"/usr/$(get_libdir)/lib{cap,psx}.a || die - fi - - # install pam plugins ourselves - rm -rf "${ED}"/usr/$(get_libdir)/security || die - - if use pam ; then - dopammod pam_cap/pam_cap.so - dopamsecurity '' pam_cap/capability.conf - fi -} - -multilib_src_install_all() { - dodoc CHANGELOG README doc/capability.notes -} diff --git a/sys-libs/libcap/libcap-2.58.ebuild b/sys-libs/libcap/libcap-2.58.ebuild deleted file mode 100644 index ea1e6af49768..000000000000 --- a/sys-libs/libcap/libcap-2.58.ebuild +++ /dev/null @@ -1,88 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -inherit multilib-minimal toolchain-funcs pam usr-ldscript - -DESCRIPTION="POSIX 1003.1e capabilities" -HOMEPAGE="https://sites.google.com/site/fullycapable/" -SRC_URI="https://www.kernel.org/pub/linux/libs/security/linux-privs/libcap2/${P}.tar.xz" - -# it's available under either of the licenses -LICENSE="|| ( GPL-2 BSD )" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux" -IUSE="pam static-libs tools" - -# While the build system optionally uses gperf, we don't DEPEND on it because -# the build automatically falls back when it's unavailable. #604802 -PDEPEND="pam? ( sys-libs/pam[${MULTILIB_USEDEP}] )" -DEPEND="${PDEPEND} - sys-kernel/linux-headers" -BDEPEND="tools? ( dev-lang/go )" - -PATCHES=( - "${FILESDIR}"/${PN}-2.38-no_perl.patch - "${FILESDIR}"/${PN}-2.25-ignore-RAISE_SETFCAP-install-failures.patch -) - -QA_FLAGS_IGNORED="sbin/captree" # go binaries don't use LDFLAGS - -src_prepare() { - default - multilib_copy_sources -} - -run_emake() { - local args=( - AR="$(tc-getAR)" - CC="$(tc-getCC)" - OBJCOPY="$(tc-getOBJCOPY)" - RANLIB="$(tc-getRANLIB)" - exec_prefix="${EPREFIX}" - lib_prefix="${EPREFIX}/usr" - lib="$(get_libdir)" - prefix="${EPREFIX}/usr" - PAM_CAP="$(usex pam yes no)" - DYNAMIC=yes - GOLANG="$(multilib_native_usex tools yes no)" - ) - emake "${args[@]}" "$@" -} - -src_configure() { - tc-export_build_env BUILD_CC - multilib-minimal_src_configure -} - -multilib_src_compile() { - run_emake -} - -multilib_src_test() { - run_emake test -} - -multilib_src_install() { - # no configure, needs explicit install line #444724#c3 - run_emake DESTDIR="${D}" install - - gen_usr_ldscript -a cap - gen_usr_ldscript -a psx - if ! use static-libs ; then - rm "${ED}"/usr/$(get_libdir)/lib{cap,psx}.a || die - fi - - # install pam plugins ourselves - rm -rf "${ED}"/usr/$(get_libdir)/security || die - - if use pam ; then - dopammod pam_cap/pam_cap.so - dopamsecurity '' pam_cap/capability.conf - fi -} - -multilib_src_install_all() { - dodoc CHANGELOG README doc/capability.notes -} diff --git a/sys-libs/libcap/libcap-2.59.ebuild b/sys-libs/libcap/libcap-2.59.ebuild deleted file mode 100644 index ea1e6af49768..000000000000 --- a/sys-libs/libcap/libcap-2.59.ebuild +++ /dev/null @@ -1,88 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -inherit multilib-minimal toolchain-funcs pam usr-ldscript - -DESCRIPTION="POSIX 1003.1e capabilities" -HOMEPAGE="https://sites.google.com/site/fullycapable/" -SRC_URI="https://www.kernel.org/pub/linux/libs/security/linux-privs/libcap2/${P}.tar.xz" - -# it's available under either of the licenses -LICENSE="|| ( GPL-2 BSD )" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux" -IUSE="pam static-libs tools" - -# While the build system optionally uses gperf, we don't DEPEND on it because -# the build automatically falls back when it's unavailable. #604802 -PDEPEND="pam? ( sys-libs/pam[${MULTILIB_USEDEP}] )" -DEPEND="${PDEPEND} - sys-kernel/linux-headers" -BDEPEND="tools? ( dev-lang/go )" - -PATCHES=( - "${FILESDIR}"/${PN}-2.38-no_perl.patch - "${FILESDIR}"/${PN}-2.25-ignore-RAISE_SETFCAP-install-failures.patch -) - -QA_FLAGS_IGNORED="sbin/captree" # go binaries don't use LDFLAGS - -src_prepare() { - default - multilib_copy_sources -} - -run_emake() { - local args=( - AR="$(tc-getAR)" - CC="$(tc-getCC)" - OBJCOPY="$(tc-getOBJCOPY)" - RANLIB="$(tc-getRANLIB)" - exec_prefix="${EPREFIX}" - lib_prefix="${EPREFIX}/usr" - lib="$(get_libdir)" - prefix="${EPREFIX}/usr" - PAM_CAP="$(usex pam yes no)" - DYNAMIC=yes - GOLANG="$(multilib_native_usex tools yes no)" - ) - emake "${args[@]}" "$@" -} - -src_configure() { - tc-export_build_env BUILD_CC - multilib-minimal_src_configure -} - -multilib_src_compile() { - run_emake -} - -multilib_src_test() { - run_emake test -} - -multilib_src_install() { - # no configure, needs explicit install line #444724#c3 - run_emake DESTDIR="${D}" install - - gen_usr_ldscript -a cap - gen_usr_ldscript -a psx - if ! use static-libs ; then - rm "${ED}"/usr/$(get_libdir)/lib{cap,psx}.a || die - fi - - # install pam plugins ourselves - rm -rf "${ED}"/usr/$(get_libdir)/security || die - - if use pam ; then - dopammod pam_cap/pam_cap.so - dopamsecurity '' pam_cap/capability.conf - fi -} - -multilib_src_install_all() { - dodoc CHANGELOG README doc/capability.notes -} diff --git a/sys-libs/libcap/libcap-2.60.ebuild b/sys-libs/libcap/libcap-2.61.ebuild index ea1e6af49768..28b28501b9d6 100644 --- a/sys-libs/libcap/libcap-2.60.ebuild +++ b/sys-libs/libcap/libcap-2.61.ebuild @@ -20,11 +20,14 @@ IUSE="pam static-libs tools" PDEPEND="pam? ( sys-libs/pam[${MULTILIB_USEDEP}] )" DEPEND="${PDEPEND} sys-kernel/linux-headers" -BDEPEND="tools? ( dev-lang/go )" +BDEPEND=" + sys-apps/diffutils + tools? ( dev-lang/go )" PATCHES=( - "${FILESDIR}"/${PN}-2.38-no_perl.patch - "${FILESDIR}"/${PN}-2.25-ignore-RAISE_SETFCAP-install-failures.patch + "${FILESDIR}"/${PN}-2.61-no_perl.patch + "${FILESDIR}"/${PN}-2.61-ignore-RAISE_SETFCAP-install-failures.patch + "${FILESDIR}"/${PN}-2.61-Wformat.patch ) QA_FLAGS_IGNORED="sbin/captree" # go binaries don't use LDFLAGS |