From 0dec76c50486a18757cddb8e61b4dec07f79086a Mon Sep 17 00:00:00 2001 From: Karsten Hopp Date: Wed, 16 Apr 2014 11:54:54 +0200 Subject: [PATCH] update to 2.24 dropped patch for rhbz#911878, it is upstream now --- .gitignore | 1 + libcap-2.22-signed-sizeof-compare.patch | 21 ------------------- ...lags.patch => libcap-2.24-buildflags.patch | 13 ++++++------ libcap.spec | 18 +++++++++------- sources | 2 +- 5 files changed, 19 insertions(+), 36 deletions(-) delete mode 100644 libcap-2.22-signed-sizeof-compare.patch rename libcap-2.22-buildflags.patch => libcap-2.24-buildflags.patch (56%) diff --git a/.gitignore b/.gitignore index 0479603..5fdb45f 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ libcap-2.17.tar.gz /libcap-2.22.tar.bz2 +/libcap-2.24.tar.gz diff --git a/libcap-2.22-signed-sizeof-compare.patch b/libcap-2.22-signed-sizeof-compare.patch deleted file mode 100644 index 4ada3fa..0000000 --- a/libcap-2.22-signed-sizeof-compare.patch +++ /dev/null @@ -1,21 +0,0 @@ -diff -up libcap-2.22/libcap/cap_file.c.911878 libcap-2.22/libcap/cap_file.c ---- libcap-2.22/libcap/cap_file.c.911878 2013-05-14 11:45:25.569448468 +0200 -+++ libcap-2.22/libcap/cap_file.c 2013-05-14 11:47:04.712036407 +0200 -@@ -187,7 +187,7 @@ cap_t cap_get_fd(int fildes) - /* fill the capability sets via a system call */ - sizeofcaps = fgetxattr(fildes, XATTR_NAME_CAPS, - &rawvfscap, sizeof(rawvfscap)); -- if (sizeofcaps < sizeof(rawvfscap.magic_etc)) { -+ if (sizeofcaps < (int) sizeof(rawvfscap.magic_etc)) { - cap_free(result); - result = NULL; - } else { -@@ -217,7 +217,7 @@ cap_t cap_get_file(const char *filename) - /* fill the capability sets via a system call */ - sizeofcaps = getxattr(filename, XATTR_NAME_CAPS, - &rawvfscap, sizeof(rawvfscap)); -- if (sizeofcaps < sizeof(rawvfscap.magic_etc)) { -+ if (sizeofcaps < (int) sizeof(rawvfscap.magic_etc)) { - cap_free(result); - result = NULL; - } else { diff --git a/libcap-2.22-buildflags.patch b/libcap-2.24-buildflags.patch similarity index 56% rename from libcap-2.22-buildflags.patch rename to libcap-2.24-buildflags.patch index 7e204af..588eff8 100644 --- a/libcap-2.22-buildflags.patch +++ b/libcap-2.24-buildflags.patch @@ -1,16 +1,17 @@ -diff -up libcap-2.22/Make.Rules~ libcap-2.22/Make.Rules ---- libcap-2.22/Make.Rules~ 2011-07-25 05:18:23.000000000 +0300 -+++ libcap-2.22/Make.Rules 2013-02-24 20:58:45.681474100 +0200 -@@ -48,7 +48,7 @@ KERNEL_HEADERS := $(topdir)/libcap/inclu - IPATH += -fPIC -I$(topdir)/libcap/include -I$(KERNEL_HEADERS) +diff -up libcap-2.24/Make.Rules.rh libcap-2.24/Make.Rules +--- libcap-2.24/Make.Rules.rh 2014-04-16 11:01:44.027253230 +0200 ++++ libcap-2.24/Make.Rules 2014-04-16 11:02:40.340233607 +0200 +@@ -49,7 +49,8 @@ KERNEL_HEADERS := $(topdir)/libcap/inclu + IPATH += -fPIC -I$(KERNEL_HEADERS) -I$(topdir)/libcap/include CC := gcc -CFLAGS := -O2 -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 +CFLAGS := $(RPM_OPT_FLAGS) -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 ++ BUILD_CC := $(CC) BUILD_CFLAGS := $(CFLAGS) $(IPATH) AR := ar -@@ -59,7 +59,7 @@ WARNINGS=-Wall -Wwrite-strings \ +@@ -60,7 +61,7 @@ WARNINGS=-Wall -Wwrite-strings \ -Wstrict-prototypes -Wmissing-prototypes \ -Wnested-externs -Winline -Wshadow LD=$(CC) -Wl,-x -shared diff --git a/libcap.spec b/libcap.spec index 10894e2..d92683c 100644 --- a/libcap.spec +++ b/libcap.spec @@ -1,14 +1,12 @@ Name: libcap -Version: 2.22 -Release: 7%{?dist} +Version: 2.24 +Release: 1%{?dist} Summary: Library for getting and setting POSIX.1e capabilities -# Original tarball should be here, but got deleted: -#Source: http://www.kernel.org/pub/linux/libs/security/linux-privs/kernel-2.6/libcap-2.22.tar.bz2 -Source: http://mirror.linux.org.au/linux/libs/security/linux-privs/libcap2/%{name}-%{version}.tar.bz2 +#Source: http://mirror.linux.org.au/linux/libs/security/linux-privs/libcap2/%{name}-%{version}.tar.bz2 +Source: https://www.kernel.org/pub/linux/libs/security/linux-privs/libcap2/%{name}-%{version}.tar.gz # http://manned.org/getpcaps/299a4949/src: Source1: getpcaps.8 -Patch0: %{name}-2.22-buildflags.patch -Patch1: libcap-2.22-signed-sizeof-compare.patch +Patch0: %{name}-2.24-buildflags.patch URL: http://ftp.kernel.org/pub/linux/libs/security/linux-privs/kernel-2.6/ License: LGPLv2+ @@ -36,7 +34,6 @@ libcap. %prep %setup -q %patch0 -p1 -%patch1 -p1 %build # libcap can not be build with _smp_mflags: @@ -76,11 +73,16 @@ chmod +x %{buildroot}/%{_libdir}/*.so.* %{_includedir}/* /%{_libdir}/*.so %{_mandir}/man3/* +%{_libdir}/pkgconfig/libcap.pc %clean rm -rf %{buildroot} %changelog +* Wed Apr 16 2014 Karsten Hopp 2.24-1 +- update to 2.24 +- dropped patch for rhbz#911878, it is upstream now + * Sat Aug 03 2013 Fedora Release Engineering - 2.22-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild diff --git a/sources b/sources index 5bd38b6..63ec7c8 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -ce64058bdb3f086ddbfca8ce6c919845 libcap-2.22.tar.bz2 +ffb154f29b1d28466c6fe6add8286a2d libcap-2.24.tar.gz