# # spec file for package libcap (Version 2.10) # # Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany. # This file and all modifications and additions to the pristine # package are under the same license as the package itself. # # Please submit bugfixes or comments via http://bugs.opensuse.org/ # # norootforbuild Name: libcap BuildRequires: fdupes libattr-devel License: BSD 3-Clause Group: System/Libraries AutoReqProv: on Summary: Library for Capabilities (linux-privs) Support Version: 2.10 Release: 2 Source: ftp://ftp.de.kernel.org/pub/linux/libs/security/linux-privs/libcap2/libcap-%{version}.tar.bz2 Patch: libcap-dynamic-link.diff #URL: http://www.kernel.org/ BuildRoot: %{_tmppath}/%{name}-%{version}-build %define debug_package_requires libcap2 = %{version} %description Capabilities are a measure to limit the omnipotence of the superuser. Currently a program started by root or setuid root has the power to do anything. Capabilities (Linux-Privs) provide a more fine-grained access control. Without kernel patches, you can use this library to drop capabilities within setuid binaries. If you use patches, this can be done automatically by the kernel. %package -n libcap2 License: BSD 3-Clause Summary: Library for Capabilities (linux-privs) Support Group: System/Libraries %description -n libcap2 Capabilities are a measure to limit the omnipotence of the superuser. Currently a program started by root or setuid root has the power to do anything. Capabilities (Linux-Privs) provide a more fine-grained access control. Without kernel patches, you can use this library to drop capabilities within setuid binaries. If you use patches, this can be done automatically by the kernel. %package devel License: BSD 3-Clause Summary: Development files for libcap Group: Development/Libraries/C and C++ Requires: glibc-devel libcap2 = %{version} %description devel Development files (Headers, libraries for static linking, etc) for libcap. libcap is a library for getting and setting POSIX.1e (formerly POSIX 6) draft 15 capabilities. Install libcap-devel if you want to develop or compile applications using libcap. %package progs License: BSD 3-Clause Summary: Libcap utility programs Group: System/Filesystems %description progs This package contains utility programs handling capabilities via libcap. %prep %setup -q %patch %build lib=%{_lib} make %{?jobs:-j %jobs} LDFLAGS= COPTFLAG="$RPM_OPT_FLAGS" %install make install DESTDIR=$RPM_BUILD_ROOT LIBDIR=$RPM_BUILD_ROOT/%{_lib} MANDIR=$RPM_BUILD_ROOT%{_mandir} # move *.so file to libdir and relink rm -f $RPM_BUILD_ROOT/%{_lib}/*.so mkdir -p $RPM_BUILD_ROOT%{_libdir} ln -s /%{_lib}/libcap.so.2 $RPM_BUILD_ROOT%{_libdir}/libcap.so %fdupes -s $RPM_BUILD_ROOT %post -n libcap2 -p /sbin/ldconfig %postun -n libcap2 -p /sbin/ldconfig %files -n libcap2 %defattr(-,root,root) %attr(755,root,root) /%{_lib}/libcap.so.* %files progs %defattr(-,root,root) %doc %{_mandir}/man8/* /sbin/* %files devel %defattr(-,root,root) %doc License README CHANGELOG %{_includedir}/sys/capability.h %{_libdir}/*.so %doc %{_mandir}/man?/* %changelog * Mon Aug 04 2008 ro@suse.de - fix requires for debuginfo package * Wed Jun 11 2008 tiwai@suse.de - updated to libcap-2.10: v3 capabilities, documantation fixes, misc fixes * Wed Apr 23 2008 tiwai@suse.de - updated to libcap-2.08 properly supporting the recent 2.6 kernels * Thu Apr 10 2008 ro@suse.de - added baselibs.conf file to build xxbit packages for multilib support * Mon Apr 16 2007 tiwai@suse.de - follow library packaging policy * move docs to devel package * move binaries and man pages to progs sub package * fix *.so symlink in libdir * Wed Jan 24 2007 tiwai@suse.de - fix the access over array range in cap_extint.c (#237943). * Tue Dec 19 2006 tiwai@suse.de - update to libcap-1.10 to support fscaps (#229722, FATE#301748) * Wed May 24 2006 schwab@suse.de - Don't strip binaries. * Thu May 11 2006 tiwai@suse.de - fix invalid calls of free() (#174561) * Wed Jan 25 2006 mls@suse.de - converted neededforbuild to BuildRequires * Fri Aug 19 2005 kukuk@suse.de - Create -devel subpackage * Thu Jun 23 2005 meissner@suse.de - use RPM_OPT_FLAGS. * Wed May 25 2005 tiwai@suse.de - fixed memory leak (#85659) * Wed Jan 19 2005 tiwai@suse.de - fixed compile warnings with gcc-4.0. * Thu Mar 25 2004 thomas@suse.de - added EAL3 man-page patch * Tue Jan 27 2004 kukuk@suse.de - Remove capget.2/capset.2 from package (version from man-pages is newer). * Sun Jan 11 2004 adrian@suse.de - add %%run_ldconfig * Mon Feb 24 2003 schwab@suse.de - Don't include kernel headers, instead copy the contents here. * Thu Feb 06 2003 garloff@suse.de - Avoid inclusion of glibc's linux/fs.h (it's broken) [#23324]. - Use BuildRoot. * Wed Nov 27 2002 coolo@suse.de - link the library with the compiler so the depedencies are tracked correctly (#21996) * Tue Sep 17 2002 ro@suse.de - removed bogus self-provides * Wed Sep 04 2002 sf@suse.de - fix biarch error (added patch to Make.Rules) * Mon Aug 12 2002 kukuk@suse.de - Remove kernel-source from neededforbuild * Sat Apr 20 2002 garloff@suse.de - Include capfaq-0.2.txt - Disable syscall wrapper (capset/capget); it's defined in glibc. * Sat Apr 20 2002 garloff@suse.de - Compile syscall wrapper without -fPIC * Tue Apr 09 2002 ro@suse.de - apply gcc-3 fixes only for gcc-3 * Mon Mar 25 2002 stepan@suse.de - remove -ansi, as it forbids inline. (gcc3) - use -fpic for building libraries (gcc3) * Thu Sep 06 2001 ro@suse.de - updated neededforbuild and updated specfile (man and doc relocation) * Wed Sep 29 1999 garloff@suse.de - Initial check in of libcap. - Kernel patches are provided within the docdir.