libcap-vl.spec 7.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261
  1. %define build_compat32 %{?_with_compat32:1}%{!?_with_compat32:0}
  2. Summary: Library for getting and setting POSIX.1e capabilities
  3. Summary(ja): POSIX.1e ケーパビリティを取得・設定するためのライブラリ
  4. Name: libcap
  5. Version: 2.25
  6. Release: 1%{?_dist_release}
  7. License: LGPLv2
  8. Group: System Environment/Libraries
  9. Vendor: Project Vine
  10. Distribution: Vine Linux
  11. Source: http://www.kernel.org/pub/linux/libs/security/linux-privs/kernel-2.6/%{name}-%{version}.tar.xz
  12. Source1: getpcaps.8
  13. # Patch0: libcap-2.16-headerfix.patch
  14. Patch1: %{name}-2.25-buildflags.patch
  15. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  16. BuildRequires: libattr-devel
  17. BuildRequires: pam-devel
  18. %description
  19. libcap is a library for getting and setting POSIX.1e (formerly POSIX 6)
  20. draft 15 capabilities.
  21. %package devel
  22. Summary: Development files for libcap
  23. Summary(ja): libcap の開発用ファイル
  24. Group: Development/Libraries
  25. Requires: %{name} = %{version}-%{release}
  26. %description devel
  27. Development files (Headers, libraries for static linking, etc) for libcap.
  28. libcap is a library for getting and setting POSIX.1e (formerly POSIX 6)
  29. draft 15 capabilities.
  30. Install libcap-devel if you want to develop or compile applications using
  31. libcap.
  32. %package static
  33. Summary: static library of libcap
  34. Summary(ja): libcap のスタティックライブラリ
  35. Group: Development/Libraries
  36. Requires: %{name}-devel = %{version}-%{release}
  37. %description static
  38. This package includes the static library of libpcap
  39. # compat32
  40. %package -n compat32-%{name}
  41. Summary: Library for getting and setting POSIX.1e capabilities
  42. Summary(ja): POSIX.1e ケーパビリティを取得・設定するためのライブラリ
  43. Group: System Environment/Libraries
  44. %description -n compat32-%{name}
  45. libcap is a library for getting and setting POSIX.1e (formerly POSIX 6)
  46. draft 15 capabilities.
  47. %package -n compat32-%{name}-devel
  48. Summary: Development files for libcap
  49. Summary(ja): libcap の開発用ファイル
  50. Group: Development/Libraries
  51. Requires: compat32-%{name} = %{version}-%{release}
  52. Requires: %{name}-devel = %{version}-%{release}
  53. %description -n compat32-%{name}-devel
  54. Development files (Headers, libraries for static linking, etc) for libcap.
  55. libcap is a library for getting and setting POSIX.1e (formerly POSIX 6)
  56. draft 15 capabilities.
  57. Install libcap-devel if you want to develop or compile applications using
  58. libcap.
  59. %prep
  60. %setup -q
  61. # %patch0 -p1
  62. %patch1 -p1
  63. %build
  64. # libcap can not be build with _smp_mflags:
  65. make PREFIX=%{_prefix} LIBDIR=%{_libdir} SBINDIR=%{_sbindir} \
  66. INCDIR=%{_includedir} MANDIR=%{_mandir} COPTFLAG="$RPM_OPT_FLAGS"
  67. %install
  68. rm -rf $RPM_BUILD_ROOT
  69. make install RAISE_SETFCAP=no \
  70. DESTDIR=${RPM_BUILD_ROOT} \
  71. LIBDIR=/%{_lib} \
  72. SBINDIR=%{_sbindir} \
  73. INCDIR=%{_includedir} \
  74. MANDIR=%{_mandir}/ \
  75. PKGCONFIGDIR=%{_libdir}/pkgconfig/ \
  76. COPTFLAG="$RPM_OPT_FLAGS"
  77. mkdir -p ${RPM_BUILD_ROOT}/%{_mandir}/man{2,3,8}
  78. #mv -f doc/*.2 ${RPM_BUILD_ROOT}/%{_mandir}/man2/
  79. mv -f doc/*.3 ${RPM_BUILD_ROOT}/%{_mandir}/man3/
  80. chmod +x $RPM_BUILD_ROOT/%{_lib}/*.so.*
  81. # need to build init.lxc.static
  82. mv %{buildroot}/%{_lib}/libcap.a %{buildroot}/%{_libdir}/libcap.a
  83. cp -f %{SOURCE1} %{buildroot}/%{_mandir}/man8/
  84. %clean
  85. rm -rf $RPM_BUILD_ROOT
  86. %post -p /sbin/ldconfig
  87. %postun -p /sbin/ldconfig
  88. %post -n compat32-%{name} -p /sbin/ldconfig
  89. %postun -n compat32-%{name} -p /sbin/ldconfig
  90. %files
  91. %defattr(-,root,root)
  92. %doc doc/capability.notes License
  93. /%{_lib}/*.so.*
  94. %{_sbindir}/*
  95. %{_mandir}/man1/*
  96. %{_mandir}/man8/*
  97. /%{_lib}/security/pam_cap.so
  98. %files devel
  99. %defattr(-,root,root)
  100. %{_includedir}/*
  101. /%{_lib}/*.so
  102. %{_libdir}/pkgconfig/*
  103. %{_mandir}/man3/*
  104. %files static
  105. %defattr(-,root,root)
  106. %{_libdir}/*.a
  107. # compat32
  108. %if %{build_compat32}
  109. %files -n compat32-%{name}
  110. %defattr(-,root,root)
  111. /%{_lib}/*.so.*
  112. %files -n compat32-%{name}-devel
  113. %defattr(-,root,root)
  114. /%{_lib}/*.so
  115. %endif
  116. %changelog
  117. * Sun Jun 26 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.25-1
  118. - new upstream release.
  119. - added Source1.
  120. - added libcap-static.
  121. * Thu Jul 9 2015 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 2.24-1
  122. - new upstream release
  123. - change tarfile format
  124. - change flags in install section
  125. - add patch1, drop patch0 (patch1 from fedora)
  126. * Tue Dec 31 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.16-4
  127. - rebuild with VineSeed environment
  128. * Tue Jun 07 2011 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.16-3
  129. - add BuildRequires: pam-devel
  130. * Sat Apr 16 2011 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.16-2
  131. - rebuilt with current VineSeed
  132. * Wed Jul 15 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 2.16-1
  133. - new upstream release
  134. - remove compat library (libpcap-1.10)
  135. * Sun May 10 2009 NAKAMURA Kenta <kenta@vinelinux.org> 2.06-2
  136. - added compat32 package for x86_64 arch support
  137. * Fri Jun 20 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.06-1
  138. - source updated
  139. - built with libattr 2.4.41
  140. * Mon Mar 13 2006 Daisuke SUZUKI <daisuke@linux.or.jp> 1.10-22vl2
  141. - rebuilt
  142. * Sun Mar 20 2005 Daisuke SUZUKI <daisuke@linux.or.jp> 1.10-22vl1
  143. - initial build for Vine Linux based on FC package
  144. * Wed Mar 02 2005 Karsten Hopp <karsten@redhat.de> 1.10-22
  145. - build with gcc-4
  146. * Wed Feb 09 2005 Karsten Hopp <karsten@redhat.de> 1.10-21
  147. - rebuilt
  148. * Tue Aug 31 2004 Phil Knirsch <pknirsch@redhat.com> 1.10-20
  149. - Fix wrong typedef in userland patch (#98801)
  150. * Tue Jun 15 2004 Elliot Lee <sopwith@redhat.com>
  151. - rebuilt
  152. * Tue Mar 02 2004 Elliot Lee <sopwith@redhat.com>
  153. - rebuilt
  154. * Fri Feb 13 2004 Elliot Lee <sopwith@redhat.com>
  155. - rebuilt
  156. * Tue Jan 27 2004 Karsten Hopp <karsten@redhat.de> 1.10-17
  157. - use _manpath
  158. * Wed Jun 04 2003 Elliot Lee <sopwith@redhat.com>
  159. - rebuilt
  160. * Wed Jan 22 2003 Tim Powers <timp@redhat.com>
  161. - rebuilt
  162. * Sat Jan 4 2003 Jeff Johnson <jbj@redhat.com> 1.10-14
  163. - set execute bits on library so that requires are generated.
  164. * Thu Nov 21 2002 Mike A. Harris <mharris@redhat.com> 1.10-13
  165. - Removed %%name macro sillyness from package Summary, description text, etc.
  166. - Removed archaic Prefix: tag
  167. - lib64 fixes everywhere to use _lib, _libdir, etc
  168. - Removed deletion of RPM_BUILD_DIR from %%clean section
  169. - Added -q flag to setup macro
  170. - Severely cleaned up spec file, and removed usage of perl
  171. * Fri Jul 19 2002 Jakub Jelinek <jakub@redhat.com> 1.10-12
  172. - CFLAGS was using COPTFLAG variable, not COPTFLAGS
  173. - build with -fpic
  174. - apply the IA-64 patch everywhere, use capget/capset from glibc,
  175. not directly as _syscall (as it is broken on IA-32 with -fpic)
  176. - reenable alpha
  177. * Fri Jun 21 2002 Tim Powers <timp@redhat.com>
  178. - automated rebuild
  179. * Wed May 29 2002 Bernhard Rosenkraenzer <bero@redhat.com> 1.10-10
  180. - Exclude alpha for now, apparent gcc bug.
  181. * Fri Nov 9 2001 Bernhard Rosenkraenzer <bero@redhat.com> 1.10-6
  182. - Fix sys/capabilities.h header (#55727)
  183. - Move to /lib, some applications seem to be using this rather early
  184. (#55733)
  185. * Mon Jul 16 2001 Trond Eivind Glomsr藷?<teg@redhat.com>
  186. - Add post,postun scripts
  187. * Tue Jul 10 2001 Jakub Jelinek <jakub@redhat.com>
  188. - don't build libcap.so.1 with ld -shared, but gcc -shared
  189. * Wed Jun 20 2001 Trond Eivind Glomsr藷?<teg@redhat.com>
  190. - Rebuild - it was missing for alpha
  191. * Wed Jun 06 2001 Florian La Roche <Florian.LaRoche@redhat.de>
  192. - add s390/s390x support
  193. * Thu May 17 2001 Bernhard Rosenkraenzer <bero@redhat.com> 1.10-1
  194. - initial RPM
  195. - fix build on ia64