summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sys-libs/libcap/files')
-rw-r--r--sys-libs/libcap/files/1.10-python.patch112
-rw-r--r--sys-libs/libcap/files/2.08/0006-cleanup-build-system.patch199
-rw-r--r--sys-libs/libcap/files/2.10/0001-Make-fixes.patch43
-rw-r--r--sys-libs/libcap/files/2.10/0002-cleanup-build-system.patch198
-rw-r--r--sys-libs/libcap/files/libcap-1.10-auditcaps.diff14
-rw-r--r--sys-libs/libcap/files/libcap-1.10-headers.patch20
-rw-r--r--sys-libs/libcap/files/libcap-1.10-nostrip.patch15
-rw-r--r--sys-libs/libcap/files/libcap-1.10-r4-staticfix.diff55
8 files changed, 0 insertions, 656 deletions
diff --git a/sys-libs/libcap/files/1.10-python.patch b/sys-libs/libcap/files/1.10-python.patch
deleted file mode 100644
index 6e87babc983e..000000000000
--- a/sys-libs/libcap/files/1.10-python.patch
+++ /dev/null
@@ -1,112 +0,0 @@
-diff -ur libcap-1.10.orig/libcap/Makefile libcap-1.10/libcap/Makefile
---- libcap-1.10.orig/libcap/Makefile 2003-09-29 22:26:56.856116136 -0400
-+++ libcap-1.10/libcap/Makefile 2003-09-29 22:31:06.204209464 -0400
-@@ -33,6 +33,7 @@
- # Library version
- #
- LIBNAME=libcap
-+PYTHONMODNAME=libcapmodule.so
- #
-
- FILES=cap_alloc cap_proc cap_extint cap_flag cap_text cap_sys
-@@ -46,7 +47,11 @@
- MAJLIBNAME=$(LIBNAME).so.$(VERSION)
- MINLIBNAME=$(MAJLIBNAME).$(MINOR)
-
-+ifdef PYTHON
-+all: $(MINLIBNAME) $(LIBNAME).a $(PYTHONMODNAME)
-+else
- all: $(MINLIBNAME) $(LIBNAME).a
-+endif
-
- _makenames: _makenames.c cap_names.sed
- $(CC) $(CFLAGS) $(LDFLAGS) $< -o $@
-@@ -66,6 +71,15 @@
- ln -sf $(MINLIBNAME) $(MAJLIBNAME)
- ln -sf $(MAJLIBNAME) $(LIBNAME).so
-
-+libcap_wrap.c: include/sys/capability.h
-+ swig -python -o libcap_wrap.c include/sys/capability.h
-+
-+libcap_wrap.o: libcap_wrap.c
-+ $(CC) $(CFLAGS) -fPIC -c $< -o $@
-+
-+$(PYTHONMODNAME): $(LOBJS) libcap_wrap.o
-+ $(LD) -x -shared -o $@ libcap_wrap.o $(LOBJS)
-+
- %.o: %.c $(INCLS)
- $(CC) $(CFLAGS) -c $< -o $@
-
-@@ -82,10 +93,15 @@
- ln -sf $(MINLIBNAME) $(LIBDIR)/$(MAJLIBNAME)
- ln -sf $(MAJLIBNAME) $(LIBDIR)/$(LIBNAME).so
- -/sbin/ldconfig
-+ifdef PYTHON
-+ mkdir -p $(PYTHONMODDIR)
-+ install -m 0644 $(PYTHONMODNAME) $(PYTHONMODDIR)/$(PYTHONMODNAME)
-+ install -m 0644 libcap.py $(PYTHONMODDIR)/
-+endif
-
- clean:
- $(LOCALCLEAN)
- rm -f $(OBJS) $(LOBJS) $(LIBNAME).a $(LIBNAME).so*
-- rm -f cap_names.h cap_names.sed _makenames
-+ rm -f cap_names.h cap_names.sed _makenames libcap_wrap.c
- cd include/sys && $(LOCALCLEAN)
-
-diff -ur libcap-1.10.orig/libcap/include/sys/capability.h libcap-1.10/libcap/include/sys/capability.h
---- libcap-1.10.orig/libcap/include/sys/capability.h 2003-09-29 22:26:56.856116136 -0400
-+++ libcap-1.10/libcap/include/sys/capability.h 2003-09-29 22:29:07.457261744 -0400
-@@ -15,12 +15,23 @@
- extern "C" {
- #endif
-
-+#ifdef SWIG
-+%module libcap
-+#endif
-+
- /*
- * This file complements the kernel file by providing prototype
- * information for the user library.
- */
-
-+#ifdef SWIG
-+%{
-+#include <sys/types.h>
-+#include "libcap.h"
-+%}
-+#else
- #include <sys/types.h>
-+#endif
- /*
- * This is <linux/capability.h>
- *
-@@ -354,10 +365,12 @@
- int cap_clear(cap_t);
-
- /* libcap/cap_file.c */
-+#ifndef SWIG
- cap_t cap_get_fd(int);
- cap_t cap_get_file(const char *);
- int cap_set_fd(int, cap_t);
- int cap_set_file(const char *, cap_t);
-+#endif
-
- /* libcap/cap_proc.c */
- cap_t cap_get_proc(void);
-@@ -377,6 +390,7 @@
- * if the following _POSIX_SOURCE is _undefined_
- */
-
-+#ifndef SWIG
- #if !defined(_POSIX_SOURCE)
-
- extern int capset(cap_user_header_t header, cap_user_data_t data);
-@@ -386,6 +400,7 @@
- extern char const *_cap_names[];
-
- #endif /* !defined(_POSIX_SOURCE) */
-+#endif
-
- #ifdef __cplusplus
- }
diff --git a/sys-libs/libcap/files/2.08/0006-cleanup-build-system.patch b/sys-libs/libcap/files/2.08/0006-cleanup-build-system.patch
deleted file mode 100644
index 8b13a3b0d9b9..000000000000
--- a/sys-libs/libcap/files/2.08/0006-cleanup-build-system.patch
+++ /dev/null
@@ -1,199 +0,0 @@
-From 5ec19bea0899c6e305337331ad4f8f8669492f28 Mon Sep 17 00:00:00 2001
-From: Mike Frysinger <vapier@gentoo.org>
-Date: Sat, 16 Feb 2008 16:51:53 -0500
-Subject: [PATCH] cleanup build system
-
-This refactors the homebrewed build system to work much better "out of the
-box" for people. It moves tools/flags into appropriate env-overridable
-variables as well as simplifies the subdirectory handling and flag passing.
-A few bug fixes are also mixed in such as proper link order, parallel build
-failure due to local header generation, and splitting up of logic between
-binaries compiled and run on the build system and binaries compiled to run
-on the target system.
-
-Signed-off-by: Mike Frysinger <vapier@gentoo.org>
----
- Make.Rules | 27 +++++++++++----------------
- Makefile | 8 ++++----
- libcap/Makefile | 18 ++++++++++--------
- pam_cap/Makefile | 9 ++++++---
- progs/Makefile | 7 +++++--
- 5 files changed, 36 insertions(+), 33 deletions(-)
-
-diff --git a/Make.Rules b/Make.Rules
-index 3f38e72..17e71c1 100644
---- a/Make.Rules
-+++ b/Make.Rules
-@@ -43,33 +43,28 @@ MINOR=06
- # Compilation specifics
-
- CC ?= gcc
-+BUILD_CC ?= $(CC)
- AR ?= ar
- RANLIB ?= ranlib
--COPTFLAGS=-O2
--DEBUG=-O2 -g #-DDEBUG
--WARNINGS=-fPIC -Wall -Wwrite-strings \
-+CFLAGS ?= -O2
-+BUILD_CFLAGS ?= $(CFLAGS)
-+WARNINGS=-Wall -Wwrite-strings \
- -Wpointer-arith -Wcast-qual -Wcast-align \
- -Wstrict-prototypes -Wmissing-prototypes \
- -Wnested-externs -Winline -Wshadow
- LD=$(CC) -Wl,-x -shared
--LDFLAGS=#-g
-+LDFLAGS ?= #-g
-
- KERNEL_HEADERS = $(topdir)/libcap/include
--SYSTEM_HEADERS = /usr/include
--IPATH += -I$(topdir)/libcap/include -I$(KERNEL_HEADERS)
-+LIBCAP_CPPFLAGS = -I$(topdir)/libcap/include -I$(KERNEL_HEADERS)
-+CPPFLAGS += $(LIBCAP_CPPFLAGS)
-+BUILD_CPPFLAGS += $(LIBCAP_CPPFLAGS)
- INCS=$(topdir)/libcap/include/sys/capability.h
--LIBS=-L$(topdir)/libcap -lcap
--CFLAGS=-Dlinux $(WARNINGS) $(DEBUG) $(COPTFLAG) $(IPATH)
-+LDFLAGS += -L$(topdir)/libcap
-+CPPFLAGS += -Dlinux
-+CFLAGS += $(WARNINGS)
- PAM_CAP ?= $(shell if [ -f /usr/include/security/pam_modules.h ]; then echo yes ; else echo no ; fi)
- # Global cleanup stuff
-
- LOCALCLEAN=rm -f *~ core
- DISTCLEAN=@find . \( -name '*.orig' -o -name '*.rej' \) | xargs rm -f
--
--# Flags to pass down recursive makes
--
--MAKE_DEFS = CC='$(CC)' CFLAGS='$(CFLAGS)' \
-- LD='$(LD)' LIBS='$(LIBS)' LDFLAGS='$(LDFLAGS)' \
-- VERSION='$(VERSION)' MINOR='$(MINOR)' \
-- LIBDIR='$(LIBDIR)' INCDIR='$(INCDIR)' \
-- SBINDIR='$(SBINDIR)' MANDIR='$(MANDIR)'
-diff --git a/Makefile b/Makefile
-index 52f7b42..9076724 100644
---- a/Makefile
-+++ b/Makefile
-@@ -9,12 +9,12 @@ include Make.Rules
- #
-
- all install clean: %: %-here
-- $(MAKE) -C libcap $(MAKE_DEFS) $@
-+ $(MAKE) -C libcap $@
- ifneq ($(PAM_CAP),no)
-- $(MAKE) -C pam_cap $(MAKE_DEFS) $@
-+ $(MAKE) -C pam_cap $@
- endif
-- $(MAKE) -C progs $(MAKE_DEFS) $@
-- $(MAKE) -C doc $(MAKE_DEFS) $@
-+ $(MAKE) -C progs $@
-+ $(MAKE) -C doc $@
-
- all-here:
-
-diff --git a/libcap/Makefile b/libcap/Makefile
-index 09a12d2..4bcc279 100644
---- a/libcap/Makefile
-+++ b/libcap/Makefile
-@@ -17,7 +17,9 @@ OBJS=$(addsuffix .o, $(FILES))
- MAJLIBNAME=$(LIBNAME).$(VERSION)
- MINLIBNAME=$(MAJLIBNAME).$(MINOR)
- GPERF_OUTPUT = _caps_output.gperf
--LDFLAGS+=-lattr
-+LDLIBS += -lattr
-+CFLAGS += -fPIC
-+INCLS += cap_names.h
-
- all: $(MINLIBNAME) $(STALIBNAME)
-
-@@ -27,7 +29,7 @@ INCLUDE_GPERF_OUTPUT = -include $(GPERF_OUTPUT)
- endif
-
- _makenames: _makenames.c cap_names.sed
-- $(CC) $(CFLAGS) $< -o $@
-+ $(BUILD_CC) $(BUILD_CFLAGS) $(BUILD_CPPFLAGS) $< -o $@
-
- cap_names.h: _makenames
- ./_makenames > cap_names.h
-@@ -40,19 +42,19 @@ cap_names.sed: Makefile $(KERNEL_HEADERS)/linux/capability.h
- @sed -ne '/^#define[ \t]CAP[_A-Z]\+[ \t]\+[0-9]\+/{s/^#define \([^ \t]*\)[ \t]*\([^ \t]*\)/\{\"\1\",\2\},/;y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/;p;}' < $(KERNEL_HEADERS)/linux/capability.h | fgrep -v 0x > $@
-
- $(STALIBNAME): $(OBJS)
-- $(AR) rcs $(STALIBNAME) $(OBJS)
-- $(RANLIB) $(STALIBNAME)
-+ $(AR) rcs $@ $^
-+ $(RANLIB) $@
-
- $(MINLIBNAME): $(OBJS)
-- $(LD) $(LDFLAGS) $(COPTFLAG) -Wl,-soname,$(MAJLIBNAME) -o $@ $(OBJS)
-+ $(LD) $(CFLAGS) $(LDFLAGS) -Wl,-soname,$(MAJLIBNAME) -o $@ $^ $(LDLIBS)
- ln -sf $(MINLIBNAME) $(MAJLIBNAME)
- ln -sf $(MAJLIBNAME) $(LIBNAME)
-
- %.o: %.c $(INCLS)
-- $(CC) $(CFLAGS) -c $< -o $@
-+ $(CC) $(CFLAGS) $(CPPFLAGS) -c $< -o $@
-
--cap_text.o: cap_text.c $(USE_GPERF_OUTPUT) $(INCLS)
-- $(CC) $(CFLAGS) $(INCLUDE_GPERF_OUTPUT) -c $< -o $@
-+cap_text.o: cap_text.c $(USE_GPERF_OUTPUT) $(INCLS)
-+ $(CC) $(CFLAGS) $(CPPFLAGS) $(INCLUDE_GPERF_OUTPUT) -c $< -o $@
-
- install: all
- mkdir -p -m 0755 $(INCDIR)/sys
-diff --git a/pam_cap/Makefile b/pam_cap/Makefile
-index 3b3d266..e20d059 100644
---- a/pam_cap/Makefile
-+++ b/pam_cap/Makefile
-@@ -3,6 +3,9 @@
- topdir=$(shell pwd)/..
- include ../Make.Rules
-
-+LDLIBS += -lcap -lpam
-+CFLAGS += -fPIC
-+
- all: pam_cap.so
- $(MAKE) testcompile
-
-@@ -14,13 +17,13 @@ install:
- @echo "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
-
- pam_cap.so: pam_cap.o
-- $(LD) -o pam_cap.so $< $(LIBS)
-+ $(LD) $(CFLAGS) $(LDFLAGS) -o pam_cap.so $< $(LDLIBS)
-
- pam_cap.o: pam_cap.c
-- $(CC) $(CFLAGS) -c $< -o $@
-+ $(CC) $(CFLAGS) $(CPPFLAGS) -c $< -o $@
-
- testcompile: test.c pam_cap.o
-- $(CC) $(CFLAGS) -o $@ $+ -lpam -ldl $(LIBS)
-+ $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -o $@ $+ -lpam -ldl $(LDLIBS)
-
- clean:
- rm -f *.o *.so testcompile *~
-diff --git a/progs/Makefile b/progs/Makefile
-index d711656..9b6b11c 100644
---- a/progs/Makefile
-+++ b/progs/Makefile
-@@ -6,13 +6,16 @@ include $(topdir)/Make.Rules
- #
- PROGS=getpcaps getcap setcap capsh
-
-+LDFLAGS += --static
-+LDLIBS += -lcap
-+
- all: $(PROGS)
-
- $(PROGS): %: %.o
-- $(CC) --static $(COPTFLAG) $(LDFLAGS) -o $@ $< $(LIBS)
-+ $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $< $(LDLIBS)
-
- %.o: %.c $(INCS)
-- $(CC) $(CFLAGS) -c $< -o $@
-+ $(CC) $(CFLAGS) $(CPPFLAGS) -c $< -o $@
-
- install: all
- mkdir -p -m 0755 $(SBINDIR)
---
-1.5.4
-
diff --git a/sys-libs/libcap/files/2.10/0001-Make-fixes.patch b/sys-libs/libcap/files/2.10/0001-Make-fixes.patch
deleted file mode 100644
index 719f6d2d037d..000000000000
--- a/sys-libs/libcap/files/2.10/0001-Make-fixes.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 8e9b94b41f3f7e90404fe492f7bc7bc438726218 Mon Sep 17 00:00:00 2001
-From: Hao Xu <hxunix@gmail.com>
-Date: Thu, 29 May 2008 07:18:21 -0700
-Subject: [PATCH] Make fixes.
-
-Don't need to do -O2 twice.
-Install the static library with the static libraries name(!)
-
-Signed-off-by: Andrew G. Morgan <morgan@kernel.org>
----
- Make.Rules | 2 +-
- libcap/Makefile | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/Make.Rules b/Make.Rules
-index 577ceda..ca2da0d 100644
---- a/Make.Rules
-+++ b/Make.Rules
-@@ -46,7 +46,7 @@ CC ?= gcc
- AR ?= ar
- RANLIB ?= ranlib
- COPTFLAGS=-O2
--DEBUG=-O2 -g #-DDEBUG
-+DEBUG=-g #-DDEBUG
- WARNINGS=-fPIC -Wall -Wwrite-strings \
- -Wpointer-arith -Wcast-qual -Wcast-align \
- -Wstrict-prototypes -Wmissing-prototypes \
-diff --git a/libcap/Makefile b/libcap/Makefile
-index c86d765..871f727 100644
---- a/libcap/Makefile
-+++ b/libcap/Makefile
-@@ -58,7 +58,7 @@ install: all
- mkdir -p -m 0755 $(INCDIR)/sys
- install -m 0644 include/sys/capability.h $(INCDIR)/sys
- mkdir -p -m 0755 $(LIBDIR)
-- install -m 0644 $(STALIBNAME) $(LIBDIR)/$(MINLIBNAME)
-+ install -m 0644 $(STALIBNAME) $(LIBDIR)/$(STALIBNAME)
- install -m 0644 $(MINLIBNAME) $(LIBDIR)/$(MINLIBNAME)
- ln -sf $(MINLIBNAME) $(LIBDIR)/$(MAJLIBNAME)
- ln -sf $(MAJLIBNAME) $(LIBDIR)/$(LIBNAME)
---
-1.5.5.3
-
diff --git a/sys-libs/libcap/files/2.10/0002-cleanup-build-system.patch b/sys-libs/libcap/files/2.10/0002-cleanup-build-system.patch
deleted file mode 100644
index a73dd5007296..000000000000
--- a/sys-libs/libcap/files/2.10/0002-cleanup-build-system.patch
+++ /dev/null
@@ -1,198 +0,0 @@
-From c41493d80bb65e11a14f4cf6174e9d4a4b3226f3 Mon Sep 17 00:00:00 2001
-From: Mike Frysinger <vapier@gentoo.org>
-Date: Sat, 31 May 2008 22:21:31 -0400
-Subject: [PATCH] cleanup build system
-
-This refactors the homebrewed build system to work much better "out of the
-box" for people. It moves tools/flags into appropriate env-overridable
-variables as well as simplifies the subdirectory handling and flag passing.
-A few bug fixes are also mixed in such as proper link order, parallel build
-failure due to local header generation, and splitting up of logic between
-binaries compiled and run on the build system and binaries compiled to run
-on the target system.
-
-Signed-off-by: Mike Frysinger <vapier@gentoo.org>
----
- Make.Rules | 27 +++++++++++----------------
- Makefile | 8 ++++----
- libcap/Makefile | 16 +++++++++-------
- pam_cap/Makefile | 9 ++++++---
- progs/Makefile | 7 +++++--
- 5 files changed, 35 insertions(+), 32 deletions(-)
-
-diff --git a/Make.Rules b/Make.Rules
-index ca2da0d..1b14658 100644
---- a/Make.Rules
-+++ b/Make.Rules
-@@ -43,33 +43,28 @@ MINOR=10
- # Compilation specifics
-
- CC ?= gcc
-+BUILD_CC ?= $(CC)
- AR ?= ar
- RANLIB ?= ranlib
--COPTFLAGS=-O2
--DEBUG=-g #-DDEBUG
--WARNINGS=-fPIC -Wall -Wwrite-strings \
-+CFLAGS ?= -O2
-+BUILD_CFLAGS ?= $(CFLAGS)
-+WARNINGS=-Wall -Wwrite-strings \
- -Wpointer-arith -Wcast-qual -Wcast-align \
- -Wstrict-prototypes -Wmissing-prototypes \
- -Wnested-externs -Winline -Wshadow
- LD=$(CC) -Wl,-x -shared
--LDFLAGS=#-g
-+LDFLAGS ?= #-g
-
- KERNEL_HEADERS = $(topdir)/libcap/include
--SYSTEM_HEADERS = /usr/include
--IPATH += -I$(topdir)/libcap/include -I$(KERNEL_HEADERS)
-+LIBCAP_CPPFLAGS = -I$(topdir)/libcap/include -I$(KERNEL_HEADERS)
-+CPPFLAGS += $(LIBCAP_CPPFLAGS)
-+BUILD_CPPFLAGS += $(LIBCAP_CPPFLAGS)
- INCS=$(topdir)/libcap/include/sys/capability.h
--LIBS=-L$(topdir)/libcap -lcap
--CFLAGS=-Dlinux $(WARNINGS) $(DEBUG) $(COPTFLAG) $(IPATH)
-+LDFLAGS += -L$(topdir)/libcap
-+CPPFLAGS += -Dlinux
-+CFLAGS += $(WARNINGS)
- PAM_CAP ?= $(shell if [ -f /usr/include/security/pam_modules.h ]; then echo yes ; else echo no ; fi)
- # Global cleanup stuff
-
- LOCALCLEAN=rm -f *~ core
- DISTCLEAN=@find . \( -name '*.orig' -o -name '*.rej' \) | xargs rm -f
--
--# Flags to pass down recursive makes
--
--MAKE_DEFS = CC='$(CC)' CFLAGS='$(CFLAGS)' \
-- LD='$(LD)' LIBS='$(LIBS)' LDFLAGS='$(LDFLAGS)' \
-- VERSION='$(VERSION)' MINOR='$(MINOR)' \
-- LIBDIR='$(LIBDIR)' INCDIR='$(INCDIR)' \
-- SBINDIR='$(SBINDIR)' MANDIR='$(MANDIR)'
-diff --git a/Makefile b/Makefile
-index 52f7b42..9076724 100644
---- a/Makefile
-+++ b/Makefile
-@@ -9,12 +9,12 @@ include Make.Rules
- #
-
- all install clean: %: %-here
-- $(MAKE) -C libcap $(MAKE_DEFS) $@
-+ $(MAKE) -C libcap $@
- ifneq ($(PAM_CAP),no)
-- $(MAKE) -C pam_cap $(MAKE_DEFS) $@
-+ $(MAKE) -C pam_cap $@
- endif
-- $(MAKE) -C progs $(MAKE_DEFS) $@
-- $(MAKE) -C doc $(MAKE_DEFS) $@
-+ $(MAKE) -C progs $@
-+ $(MAKE) -C doc $@
-
- all-here:
-
-diff --git a/libcap/Makefile b/libcap/Makefile
-index 871f727..86a7289 100644
---- a/libcap/Makefile
-+++ b/libcap/Makefile
-@@ -17,7 +17,9 @@ OBJS=$(addsuffix .o, $(FILES))
- MAJLIBNAME=$(LIBNAME).$(VERSION)
- MINLIBNAME=$(MAJLIBNAME).$(MINOR)
- GPERF_OUTPUT = _caps_output.gperf
--LDFLAGS+=-lattr
-+LDLIBS += -lattr
-+CFLAGS += -fPIC
-+INCLS += cap_names.h
-
- all: $(MINLIBNAME) $(STALIBNAME)
-
-@@ -27,7 +29,7 @@ INCLUDE_GPERF_OUTPUT = -include $(GPERF_OUTPUT)
- endif
-
- _makenames: _makenames.c cap_names.sed
-- $(CC) $(CFLAGS) $< -o $@
-+ $(BUILD_CC) $(BUILD_CFLAGS) $(BUILD_CPPFLAGS) $< -o $@
-
- cap_names.h: _makenames
- ./_makenames > cap_names.h
-@@ -40,19 +42,19 @@ cap_names.sed: Makefile $(KERNEL_HEADERS)/linux/capability.h
- @sed -ne '/^#define[ \t]CAP[_A-Z]\+[ \t]\+[0-9]\+/{s/^#define \([^ \t]*\)[ \t]*\([^ \t]*\)/\{\"\1\",\2\},/;y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/;p;}' < $(KERNEL_HEADERS)/linux/capability.h | fgrep -v 0x > $@
-
- $(STALIBNAME): $(OBJS)
-- $(AR) rcs $(STALIBNAME) $(OBJS)
-- $(RANLIB) $(STALIBNAME)
-+ $(AR) rcs $@ $^
-+ $(RANLIB) $@
-
- $(MINLIBNAME): $(OBJS)
-- $(LD) $(LDFLAGS) $(COPTFLAG) -Wl,-soname,$(MAJLIBNAME) -o $@ $(OBJS)
-+ $(LD) $(CFLAGS) $(LDFLAGS) -Wl,-soname,$(MAJLIBNAME) -o $@ $^ $(LDLIBS)
- ln -sf $(MINLIBNAME) $(MAJLIBNAME)
- ln -sf $(MAJLIBNAME) $(LIBNAME)
-
- %.o: %.c $(INCLS)
-- $(CC) $(CFLAGS) -c $< -o $@
-+ $(CC) $(CFLAGS) $(CPPFLAGS) -c $< -o $@
-
- cap_text.o: cap_text.c $(USE_GPERF_OUTPUT) $(INCLS)
-- $(CC) $(CFLAGS) $(INCLUDE_GPERF_OUTPUT) -c $< -o $@
-+ $(CC) $(CFLAGS) $(CPPFLAGS) $(INCLUDE_GPERF_OUTPUT) -c $< -o $@
-
- install: all
- mkdir -p -m 0755 $(INCDIR)/sys
-diff --git a/pam_cap/Makefile b/pam_cap/Makefile
-index 8819af2..bef59d2 100644
---- a/pam_cap/Makefile
-+++ b/pam_cap/Makefile
-@@ -3,6 +3,9 @@
- topdir=$(shell pwd)/..
- include ../Make.Rules
-
-+LDLIBS += -lcap
-+CFLAGS += -fPIC
-+
- all: pam_cap.so
- $(MAKE) testcompile
-
-@@ -11,13 +14,13 @@ install: all
- install -m 0755 pam_cap.so $(LIBDIR)/security
-
- pam_cap.so: pam_cap.o
-- $(LD) -o pam_cap.so $< $(LIBS)
-+ $(LD) $(CFLAGS) $(LDFLAGS) -o pam_cap.so $< $(LDLIBS)
-
- pam_cap.o: pam_cap.c
-- $(CC) $(CFLAGS) -c $< -o $@
-+ $(CC) $(CFLAGS) $(CPPFLAGS) -c $< -o $@
-
- testcompile: test.c pam_cap.o
-- $(CC) $(CFLAGS) -o $@ $+ -lpam -ldl $(LIBS)
-+ $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -o $@ $+ -lpam -ldl $(LDLIBS)
-
- clean:
- rm -f *.o *.so testcompile *~
-diff --git a/progs/Makefile b/progs/Makefile
-index ee03efa..f568225 100644
---- a/progs/Makefile
-+++ b/progs/Makefile
-@@ -6,13 +6,16 @@ include $(topdir)/Make.Rules
- #
- PROGS=getpcaps getcap setcap capsh
-
-+LDFLAGS += --static
-+LDLIBS += -lcap
-+
- all: $(PROGS)
-
- $(PROGS): %: %.o
-- $(CC) --static $(COPTFLAG) $(LDFLAGS) -o $@ $< $(LIBS)
-+ $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $< $(LDLIBS)
-
- %.o: %.c $(INCS)
-- $(CC) $(CFLAGS) -c $< -o $@
-+ $(CC) $(CFLAGS) $(CPPFLAGS) -c $< -o $@
-
- install: all
- mkdir -p -m 0755 $(SBINDIR)
---
-1.5.5.3
-
diff --git a/sys-libs/libcap/files/libcap-1.10-auditcaps.diff b/sys-libs/libcap/files/libcap-1.10-auditcaps.diff
deleted file mode 100644
index efb0a8bc4a89..000000000000
--- a/sys-libs/libcap/files/libcap-1.10-auditcaps.diff
+++ /dev/null
@@ -1,14 +0,0 @@
-diff -urN libcap-1.10.orig/libcap/include/sys/capability.h libcap-1.10/libcap/include/sys/capability.h
---- libcap-1.10.orig/libcap/include/sys/capability.h 2007-04-01 19:54:19.660718912 -0400
-+++ libcap-1.10/libcap/include/sys/capability.h 2007-04-01 19:56:04.272759689 -0400
-@@ -311,6 +311,10 @@
-
- #define CAP_LEASE 28
-
-+#define CAP_AUDIT_WRITE 29
-+
-+#define CAP_AUDIT_CONTROL 30
-+
- #endif /* !_LINUX_CAPABILITY_H */
-
-
diff --git a/sys-libs/libcap/files/libcap-1.10-headers.patch b/sys-libs/libcap/files/libcap-1.10-headers.patch
deleted file mode 100644
index a936b882ea37..000000000000
--- a/sys-libs/libcap/files/libcap-1.10-headers.patch
+++ /dev/null
@@ -1,20 +0,0 @@
---- progs/sucap.c
-+++ progs/sucap.c
-@@ -11,6 +11,7 @@
- #include <sys/types.h>
- #include <errno.h>
- #include <stdio.h>
-+#include <stdlib.h>
- #undef _POSIX_SOURCE
- #include <sys/capability.h>
- #include <pwd.h>
---- progs/execcap.c
-+++ progs/execcap.c
-@@ -10,6 +10,7 @@
- #include <sys/types.h>
- #include <errno.h>
- #include <stdio.h>
-+#include <stdlib.h>
- #include <sys/capability.h>
- #include <unistd.h>
- #include <string.h>
diff --git a/sys-libs/libcap/files/libcap-1.10-nostrip.patch b/sys-libs/libcap/files/libcap-1.10-nostrip.patch
deleted file mode 100644
index 9908b75520c3..000000000000
--- a/sys-libs/libcap/files/libcap-1.10-nostrip.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-let portage do the stripping
-
-http://bugs.gentoo.org/133580
-
---- libcap-1.10/progs/Makefile
-+++ libcap-1.10/progs/Makefile
-@@ -44,7 +44,7 @@ $(PROGS): %: %.o
- install: all
- mkdir -p -m 0755 $(SBINDIR)
- for p in $(PROGS) ; do \
-- install -s -m 0755 $$p $(SBINDIR) ; \
-+ install -m 0755 $$p $(SBINDIR) ; \
- done
-
- clean:
diff --git a/sys-libs/libcap/files/libcap-1.10-r4-staticfix.diff b/sys-libs/libcap/files/libcap-1.10-r4-staticfix.diff
deleted file mode 100644
index 2e8d7e0a5835..000000000000
--- a/sys-libs/libcap/files/libcap-1.10-r4-staticfix.diff
+++ /dev/null
@@ -1,55 +0,0 @@
-diff -ur libcap-1.10.orig/libcap/Makefile libcap-1.10/libcap/Makefile
---- libcap-1.10.orig/libcap/Makefile 2004-04-25 12:15:02.000000000 -0700
-+++ libcap-1.10/libcap/Makefile 2004-04-25 12:40:47.000000000 -0700
-@@ -34,6 +34,7 @@
- #
- LIBNAME=libcap
- PYTHONMODNAME=libcapmodule.so
-+STATLIBNAME=$(LIBNAME).a
- #
-
- FILES=cap_alloc cap_proc cap_extint cap_flag cap_text cap_sys
-@@ -48,9 +49,9 @@
- MINLIBNAME=$(MAJLIBNAME).$(MINOR)
-
- ifdef PYTHON
--all: $(MINLIBNAME) $(LIBNAME).a $(PYTHONMODNAME)
-+all: $(MINLIBNAME) $(STATLIBNAME) $(PYTHONMODNAME)
- else
--all: $(MINLIBNAME) $(LIBNAME).a
-+all: $(MINLIBNAME) $(STATLIBNAME)
- endif
-
- _makenames: _makenames.c cap_names.sed
-@@ -63,8 +64,8 @@
- @echo "=> making cap_names.c from <sys/capability.h>"
- @sed -ne '/^#define[ \t]CAP[_A-Z]\+[ \t]\+[0-9]\+/{s/^#define \([^ \t]*\)[ \t]*\([^ \t]*\)/ \{ \2, \"\1\" \},/;y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/;p;}' < include/sys/capability.h | fgrep -v 0x > cap_names.sed # @sed -ne '/^#define[ \t]CAP[_A-Z]\+[ \t]\+[0-9]\+/{s/^#define CAP_\([^ \t]*\)[ \t]*\([^ \t]*\)/ \{ \2, \"\1\" \},/;y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/;p;}' < /usr/include/linux/capability.h | fgrep -v 0x > cap_names.sed
-
--$(LIBNAME).a: $(OBJS)
-- ar cruv $(LIBNAME).a $(OBJS)
-+$(STATLIBNAME): $(OBJS)
-+ ar csruv $(STATLIBNAME) $(OBJS)
-
- $(MINLIBNAME): $(LOBJS)
- $(CC) -shared -fPIC -Wl,-soname,$(MAJLIBNAME) -o $@ $(LOBJS)
-@@ -88,7 +89,7 @@
- mkdir -p -m 0755 $(INCDIR)/sys
- install -m 0644 include/sys/capability.h $(INCDIR)/sys
- mkdir -p -m 0755 $(LIBDIR)
-- install -m 0644 $(LIBNAME).a $(LIBDIR)
-+ install -m 0644 $(STATLIBNAME) $(LIBDIR)
- install -m 0644 $(MINLIBNAME) $(LIBDIR)/$(MINLIBNAME)
- ln -sf $(MINLIBNAME) $(LIBDIR)/$(MAJLIBNAME)
- ln -sf $(MAJLIBNAME) $(LIBDIR)/$(LIBNAME).so
-@@ -100,7 +101,10 @@
-
- clean:
- $(LOCALCLEAN)
-- rm -f $(OBJS) $(LOBJS) $(LIBNAME).a $(LIBNAME).so*
-+ rm -f $(OBJS) $(LOBJS) $(STATLIBNAME) $(LIBNAME).so*
- rm -f cap_names.h cap_names.sed _makenames libcap_wrap.c
- cd include/sys && $(LOCALCLEAN)
-+ifdef PYTHON
-+ rm libcap.py libcap_wrap.o libcapmodule.so
-+endif
-