libcap: Update to 2.50

- Update from 2.49 to 2.50
- Update rootfile
- Version 2.50 failed to install capsh - bug raised for this
   https://bugzilla.kernel.org/show_bug.cgi?id=213261
   patch to fix this bug created and used in this build
- Changelog
   Release notes for 2.50
    2021-05-24 12:05:16 -0700
      Some new capsh features:
          --explain=cap_foo: describe what cap_foo does (Bug 212451)
          --suggest=phrase: search all the cap descriptions and describe those that match the phrase
      Add "keepcaps" module argument support to pam_cap.so (reported by Zoltan Fridrich. Bug 212945)
          extend libcap to include cap_prctl() and cap_prctlw() functions to regain feature parity with Go "cap" package. These are only needed when linking against -lpsx for keepcaps POSIX semantics.
          this likely requires substantial application changes to make Ambient capability support usable in general, but doing our part for the admin.
      Add a test case for recent kernel fix (Bug 212737)
      Go pragma fix for convenience functions in "cap" module (reported by Lorenz Bauer. Bug 212321)
      Minor man documentation updates
      Minor build tree improvements (mostly for maintainer)

Signed-off-by: Adolf Belka <adolf.belka@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
This commit is contained in:
Adolf Belka
2021-06-03 14:20:45 +02:00
committed by Michael Tremer
parent 331ba89bfd
commit 179f3ec082
3 changed files with 44 additions and 5 deletions

View File

@@ -1,10 +1,10 @@
#lib/libcap.a
lib/libcap.so.2
lib/libcap.so.2.49
lib/libcap.so.2.50
#lib/libpsx.a
#lib/libpsx.so
#lib/libpsx.so.2
#lib/libpsx.so.2.49
#lib/libpsx.so.2.50
#lib/pkgconfig/libcap.pc
#lib/pkgconfig/libpsx.pc
lib/security/pam_cap.so

View File

@@ -24,7 +24,7 @@
include Config
VER = 2.49
VER = 2.50
THISAPP = libcap-$(VER)
DL_FILE = $(THISAPP).tar.xz
@@ -40,7 +40,7 @@ objects = $(DL_FILE)
$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
$(DL_FILE)_MD5 = b43ae3690fe4d2cb32e4d25c0983ecd3
$(DL_FILE)_MD5 = 66a561afa81666236ff973544ff4e864
install : $(TARGET)
@@ -70,12 +70,13 @@ $(subst %,%_MD5,$(objects)) :
$(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
@$(PREBUILD)
@rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE)
cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/libcap-2.50-install_capsh_again.patch
# Prevent a static library from being installed
cd $(DIR_APP) && sed -i '/install.*STALIBNAME/d' libcap/Makefile
cd $(DIR_APP) && make GOLANG=no
cd $(DIR_APP) && make install GOLANG=no
rm -vf /lib/libcap.so
ln -svf /lib/libcap.so.2.49 /usr/lib/libcap.so
ln -svf /lib/libcap.so.2.50 /usr/lib/libcap.so
chmod +x /lib/libcap.so.*
@rm -rf $(DIR_APP)
@$(POSTBUILD)

View File

@@ -0,0 +1,38 @@
From 1f8d32942be54850a3a89c7b58ba5613b5525c58 Mon Sep 17 00:00:00 2001
From: "Andrew G. Morgan" <morgan@kernel.org>
Date: Fri, 28 May 2021 13:41:17 -0700
Subject: [PATCH] Make capsh an installed binary again
Bug report from Jan Palus:
https://bugzilla.kernel.org/show_bug.cgi?id=213261
Signed-off-by: Andrew G. Morgan <morgan@kernel.org>
---
progs/Makefile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/progs/Makefile b/progs/Makefile
index 313dc4d..3c3dc97 100644
--- a/progs/Makefile
+++ b/progs/Makefile
@@ -32,14 +32,14 @@ $(BUILD): %: %.o $(DEPS)
install: all
mkdir -p -m 0755 $(FAKEROOT)$(SBINDIR)
- for p in $(PROGS) ; do \
+ for p in $(PROGS) capsh ; do \
install -m 0755 $$p $(FAKEROOT)$(SBINDIR) ; \
done
ifeq ($(RAISE_SETFCAP),yes)
$(FAKEROOT)$(SBINDIR)/setcap cap_setfcap=i $(FAKEROOT)$(SBINDIR)/setcap
endif
-test: $(PROGS)
+test: $(PROGS) capsh
capshdoc.h.cf: capshdoc.h ./mkcapshdoc.sh
./mkcapshdoc.sh > $@
--
2.32.0.rc2