beecrypt-vl.spec 9.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330
  1. %define build_compat32 %{?_with_compat32:1}%{!?_with_compat32:0}
  2. %define with_python --with-python
  3. %define with_python_version %(echo `python -c "import sys; print sys.version[:3]"`)
  4. #define with_java --with-java
  5. Summary: An open source cryptography library.
  6. Name: beecrypt
  7. Version: 4.1.2
  8. Release: 13%{?_dist_release}
  9. Group: System Environment/Libraries
  10. License: LGPL
  11. URL: http://sourceforge.net/projects/beecrypt
  12. Source0: http://prdownloads.sourceforge.net/beecrypt/%{name}-%{version}.tar.gz
  13. Source1: http://prdownloads.sourceforge.net/beecrypt/%{name}-%{version}.tar.gz.sig
  14. Patch0: beecrypt-4.1.2-base64.patch
  15. Patch1: beecrypt-4.1.2-python-api.patch
  16. #BuildRequires: doxygen
  17. %if %{?with_python:1}0
  18. BuildRequires: python-devel >= %{with_python_version}
  19. %endif
  20. BuildRoot: %{_tmppath}/%{name}-root
  21. Obsoletes: beecrypt-java =< 4.1.2-2
  22. %description
  23. Beecrypt is a general-purpose cryptography library.
  24. %package devel
  25. Summary: Files needed for developing applications with beecrypt.
  26. Group: Development/Libraries
  27. Requires: %{name} = %{version}-%{release}
  28. %description devel
  29. Beecrypt is a general-purpose cryptography library. This package contains
  30. files needed for developing applications with beecrypt.
  31. ## to build compat32 for x86_64 architecture support
  32. %package -n compat32-%{name}
  33. Summary: An open source cryptography library.
  34. Group: System Environment/Libraries
  35. #BuildPreReq: doxygen
  36. %description -n compat32-%{name}
  37. Beecrypt is a general-purpose cryptography library.
  38. %package -n compat32-%{name}-devel
  39. Summary: Files needed for developing applications with beecrypt.
  40. Group: Development/Libraries
  41. Requires: %{name} = %{version}-%{release}
  42. %description -n compat32-%{name}-devel
  43. Beecrypt is a general-purpose cryptography library. This package contains
  44. files needed for developing applications with beecrypt.
  45. %if %{?with_python:1}0
  46. %package python
  47. Summary: Files needed for python applications using beecrypt.
  48. Group: Development/Libraries
  49. Requires: python >= %{with_python_version}
  50. Requires: %{name} = %{version}-%{release}
  51. %description python
  52. Beecrypt is a general-purpose cryptography library. This package contains
  53. files needed for using python with beecrypt.
  54. %endif
  55. %if %{?with_java:1}0
  56. %package java
  57. Summary: Files needed for java applications using beecrypt.
  58. Group: Development/Libraries
  59. Requires: %{name} = %{version}-%{release}
  60. %description java
  61. Beecrypt is a general-purpose cryptography library. This package contains
  62. files needed for using java with beecrypt.
  63. %endif
  64. %prep
  65. %setup -q
  66. %patch0 -p1 -b .base64
  67. %patch1 -p1 -b .python-api
  68. %build
  69. %configure --enable-shared --enable-static \
  70. %{?with_python}%{!?with_python:--with-python=no} \
  71. %{?with_java}%{!?with_java:--with-java=no} \
  72. --with-cplusplus=no
  73. make %{?_smp_mflags} \
  74. %{?with_python:pythondir="%{_libdir}/python%{with_python_version}/site-packages"}
  75. #doxygen
  76. %install
  77. rm -fr $RPM_BUILD_ROOT
  78. make install DESTDIR=$RPM_BUILD_ROOT \
  79. %{?with_python:pythondir="%{_libdir}/python%{with_python_version}/site-packages"}
  80. # XXX nuke unpackaged files, artifacts from using libtool to produce module
  81. rm -f ${RPM_BUILD_ROOT}%{_libdir}/python%{with_python_version}/site-packages/_bc.*a
  82. # XXX delete next line to build with legacy, non-check aware, rpmbuild.
  83. make check || :
  84. cat /proc/cpuinfo
  85. make bench || :
  86. ## remove unuse files
  87. rm -rf $RPM_BUILD_ROOT%{_libdir}/*.la
  88. %clean
  89. rm -fr $RPM_BUILD_ROOT
  90. %post -p /sbin/ldconfig
  91. %postun -p /sbin/ldconfig
  92. %post -n compat32-%{name} -p /sbin/ldconfig
  93. %postun -n compat32-%{name} -p /sbin/ldconfig
  94. %files
  95. %defattr(-,root,root)
  96. %doc README BENCHMARKS
  97. %{_libdir}/libbeecrypt.so.*
  98. %files devel
  99. %defattr(-,root,root)
  100. %doc BUGS
  101. %{_includedir}/%{name}
  102. %{_libdir}/libbeecrypt.a
  103. #%{_libdir}/libbeecrypt.la
  104. %{_libdir}/libbeecrypt.so
  105. %if %{?with_python:1}0
  106. %files python
  107. %defattr(-,root,root)
  108. %{_libdir}/python%{with_python_version}/site-packages/_bc.so
  109. %endif
  110. %if %{?with_java:1}0
  111. %files java
  112. %defattr(-,root,root)
  113. %{_libdir}/libbeecrypt_java.a
  114. #%{_libdir}/libbeecrypt_java.la
  115. %{_libdir}/libbeecrypt_java.so*
  116. %endif
  117. ## to build compat32 for x86_64 architecture support
  118. %if %{build_compat32}
  119. %files -n compat32-%{name}
  120. %defattr(-,root,root)
  121. %{_libdir}/libbeecrypt.so.*
  122. %files -n compat32-%{name}-devel
  123. %defattr(-,root,root)
  124. %{_libdir}/libbeecrypt.a
  125. #%{_libdir}/libbeecrypt.la
  126. %{_libdir}/libbeecrypt.so
  127. %endif
  128. %changelog
  129. * Fri Feb 12 2010 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 4.1.2-13
  130. - rebuilt with gcc-4.4.3-3 on ppc
  131. * Fri Feb 5 2010 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 4.1.2-12
  132. - rebuilt with rpm-4.8.0-3 (on ppc)
  133. * Tue Feb 02 2010 Shu KONNO <owa@bg.wakwak.com> 4.1.2-11
  134. - rebuild with python-2.6
  135. * Fri Sep 26 2008 Shu KONNO <owa@bg.wakwak.com> 4.1.2-10vl5
  136. - applied new versioning policy
  137. - removed *.la
  138. * Sat Dec 22 2007 NAKAMURA Kenta <kenta@vinelinux.org> 4.1.2-9vl5
  139. - removed %%if !%%{build_compat32} case condition
  140. * Wed May 06 2007 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 4.1.2-9vl4
  141. - rebuilt with new toolchain
  142. * Mon Feb 06 2006 Shu KONNO <owa@bg.wakwak.com> 4.1.2-9vl3
  143. - moved macros _lib to /usr/lib/rpm/rpmrc or macros files
  144. * Mon Jan 30 2006 Shu KONNO <owa@bg.wakwak.com> 4.1.2-9vl2
  145. - added compat32-* packages for x86_64 architecture support
  146. - dropt doxygen
  147. * Wed Nov 30 2005 Daisuke SUZUKI <daisuke@linux.or.jp> 4.1,2-9vl1
  148. - initial build for Vine Linux based on FC-devel
  149. * Sat Oct 15 2005 Florian La Roche <laroche@redhat.com>
  150. - Use -with-cplusplus=no. The libs still require libstdc++, so
  151. this needs further cleanup.
  152. * Tue May 17 2005 Miloslav Trmac <mitr@redhat.com> - 4.1.2-8
  153. - Remove dependencies on private symbols not present in Python 2.4 from
  154. beecrypt-python
  155. * Tue May 17 2005 Miloslav Trmac <mitr@redhat.com> - 4.1.2-7
  156. - Doh, actually apply the patch
  157. * Tue May 17 2005 Miloslav Trmac <mitr@redhat.com> - 4.1.2-6
  158. - Fix b64encode() for data starting with NUL (#123650)
  159. * Fri Apr 01 2005 Warren Togami <wtogami@redhat.com> 4.1.2-5
  160. - remove huge API docs
  161. * Fri Apr 01 2005 Paul Nasrat <pnasrat@redhat.com> 4.1.2-4
  162. - Obsolete older beecrypt-java
  163. * Tue Mar 29 2005 Paul Nasrat <pnasrat@redhat.com> 4.1.2-3
  164. - Disable beecrypt-java (#151294)
  165. * Fri Mar 4 2005 Jeff Johnson <jbj@redhat.com> 4.1.2-2
  166. - rebuild with gcc4.
  167. * Sat Feb 5 2005 Jeff Johnson <jbj@jbj.org> 4.1.2-1
  168. - upgrade to 4.1.2
  169. - put java components in sub-package.
  170. - check that /usr/lib64 is not used on alpha (#146583).
  171. * Fri Feb 4 2005 Miloslav Trmac <mitr@redhat.com> - 3.1.0-7
  172. - Rebuild against Python 2.4
  173. * Sun Aug 08 2004 Alan Cox <alan@redhat.com> 3.1.0-6
  174. - Build requires libtool (Steve Grubb)
  175. * Fri Jul 02 2004 Elliot Lee <sopwith@redhat.com> 3.1.0-5
  176. - rebuilt
  177. - Add _smp_mflags
  178. * Wed Mar 24 2004 Jeff Johnson <jbj@redhat.com> 3.1.0-3
  179. - fix: extgcd_w problem fixed by upgrading from CVS.
  180. * Tue Mar 02 2004 Elliot Lee <sopwith@redhat.com>
  181. - rebuilt
  182. * Fri Feb 13 2004 Elliot Lee <sopwith@redhat.com>
  183. - rebuilt
  184. * Mon Dec 22 2003 Jeff Johnson <jbj@jbj.org> 3.1.0-1
  185. - upgrade to 3.1.0.
  186. - recompile against python-2.3.3.
  187. * Mon Jun 30 2003 Jeff Johnson <jbj@redhat.com> 3.0.1-0.20030630
  188. - upstream fixes for DSA and ppc64.
  189. * Mon Jun 23 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-2
  190. - upgrade to 3.0.0 final.
  191. - fix for DSA (actually, modulo inverse) sometimes failing.
  192. * Fri Jun 20 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-1.20030619
  193. - avoid asm borkage on ppc64.
  194. * Thu Jun 19 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-1.20030618
  195. - rebuild for release bump.
  196. * Tue Jun 17 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-1.20030616
  197. - try to out smart libtool a different way.
  198. - use $bc_target_cpu, not $bc_target_arch, to detect /usr/lib64.
  199. * Mon Jun 16 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-1.20030615
  200. - use -mcpu=powerpc64 on ppc64.
  201. * Fri Jun 13 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-1.20030613
  202. - upgrade to latest snapshot.
  203. * Fri Jun 6 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-1.20030605
  204. - rebuild into another tree.
  205. * Wed Jun 04 2003 Elliot Lee <sopwith@redhat.com>
  206. - rebuilt
  207. * Tue Jun 3 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-0.20030603
  208. - update to 3.0.0 snapshot, fix mpmod (and DSA) on 64b platforms.
  209. * Mon Jun 2 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-0.20030602
  210. - update to 3.0.0 snapshot, merge patches, fix gcd rshift and ppc problems.
  211. * Thu May 29 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-0.20030529
  212. - update to 3.0.0 snapshot, fix ia64/x86_64 build problems.
  213. * Wed May 28 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-0.20030528
  214. - upgrade to 3.0.0 snapshot, adding rpm specific base64.[ch] changes.
  215. - add PYTHONPATH=.. so that "make check" can test the just built _bc.so module.
  216. - grab cpuinfo and run "make bench".
  217. - continue ignoring "make check" failures, LD_LIBRARY_PATH needed for _bc.so.
  218. - skip asm build failure on ia64 for now.
  219. - ignore "make bench" exit codes too, x86_64 has AES segfault.
  220. * Wed May 21 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-0.20030521
  221. - upgrade to 3.0.0 snapshot, including python subpackage.
  222. - ignore "make check" failure for now.
  223. * Fri May 16 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-0.20030516
  224. - upgrade to 3.0.0 snapshot, including ia64 and x86_64 fixes.
  225. - add %%check.
  226. - ignore "make check" failure on ia64 for now.
  227. * Mon May 12 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-0.20030512
  228. - upgrade to 3.0.0 snapshot.
  229. - add doxygen doco.
  230. - use /dev/urandom as default entropy source.
  231. - avoid known broken compilation for now.
  232. * Wed Jan 22 2003 Tim Powers <timp@redhat.com>
  233. - rebuilt
  234. * Tue Nov 19 2002 Tim Powers <timp@redhat.com>
  235. - rebuild on all arches
  236. * Fri Aug 2 2002 Jeff Johnson <jbj@redhat.com> 2.2.0-6
  237. - install types.h (#68999).
  238. * Fri Jun 21 2002 Tim Powers <timp@redhat.com>
  239. - automated rebuild
  240. * Wed Jun 5 2002 Jeff Johnson <jbj@redhat.com>
  241. - run ldconfig when installing/erasing (#65974).
  242. * Thu May 23 2002 Tim Powers <timp@redhat.com>
  243. - automated rebuild
  244. * Mon May 13 2002 Jeff Johnson <jbj@redhat.com>
  245. - upgrade to latest 2.2.0 (from cvs.rpm.org).
  246. * Mon Jan 21 2002 Jeff Johnson <jbj@redhat.com>
  247. - use the same beecrypt-2.2.0 that rpm is using internally.
  248. * Thu Jan 10 2002 Nalin Dahyabhai <nalin@redhat.com> 2.1.0-1
  249. - initial package