beecrypt-vl.spec 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336
  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: 15%{?_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. * Wed Feb 15 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> - 4.1.2-15
  130. - rebuild with python-2.7.2
  131. * Sun Apr 17 2011 Shu KONNO <owa@bg.wakwak.com> - 4.1.2-14
  132. - rebuilt with rpm-4.8.1-3
  133. * Fri Feb 12 2010 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 4.1.2-13
  134. - rebuilt with gcc-4.4.3-3 on ppc
  135. * Fri Feb 5 2010 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 4.1.2-12
  136. - rebuilt with rpm-4.8.0-3 (on ppc)
  137. * Tue Feb 02 2010 Shu KONNO <owa@bg.wakwak.com> 4.1.2-11
  138. - rebuild with python-2.6
  139. * Fri Sep 26 2008 Shu KONNO <owa@bg.wakwak.com> 4.1.2-10vl5
  140. - applied new versioning policy
  141. - removed *.la
  142. * Sat Dec 22 2007 NAKAMURA Kenta <kenta@vinelinux.org> 4.1.2-9vl5
  143. - removed %%if !%%{build_compat32} case condition
  144. * Wed May 06 2007 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 4.1.2-9vl4
  145. - rebuilt with new toolchain
  146. * Mon Feb 06 2006 Shu KONNO <owa@bg.wakwak.com> 4.1.2-9vl3
  147. - moved macros _lib to /usr/lib/rpm/rpmrc or macros files
  148. * Mon Jan 30 2006 Shu KONNO <owa@bg.wakwak.com> 4.1.2-9vl2
  149. - added compat32-* packages for x86_64 architecture support
  150. - dropt doxygen
  151. * Wed Nov 30 2005 Daisuke SUZUKI <daisuke@linux.or.jp> 4.1,2-9vl1
  152. - initial build for Vine Linux based on FC-devel
  153. * Sat Oct 15 2005 Florian La Roche <laroche@redhat.com>
  154. - Use -with-cplusplus=no. The libs still require libstdc++, so
  155. this needs further cleanup.
  156. * Tue May 17 2005 Miloslav Trmac <mitr@redhat.com> - 4.1.2-8
  157. - Remove dependencies on private symbols not present in Python 2.4 from
  158. beecrypt-python
  159. * Tue May 17 2005 Miloslav Trmac <mitr@redhat.com> - 4.1.2-7
  160. - Doh, actually apply the patch
  161. * Tue May 17 2005 Miloslav Trmac <mitr@redhat.com> - 4.1.2-6
  162. - Fix b64encode() for data starting with NUL (#123650)
  163. * Fri Apr 01 2005 Warren Togami <wtogami@redhat.com> 4.1.2-5
  164. - remove huge API docs
  165. * Fri Apr 01 2005 Paul Nasrat <pnasrat@redhat.com> 4.1.2-4
  166. - Obsolete older beecrypt-java
  167. * Tue Mar 29 2005 Paul Nasrat <pnasrat@redhat.com> 4.1.2-3
  168. - Disable beecrypt-java (#151294)
  169. * Fri Mar 4 2005 Jeff Johnson <jbj@redhat.com> 4.1.2-2
  170. - rebuild with gcc4.
  171. * Sat Feb 5 2005 Jeff Johnson <jbj@jbj.org> 4.1.2-1
  172. - upgrade to 4.1.2
  173. - put java components in sub-package.
  174. - check that /usr/lib64 is not used on alpha (#146583).
  175. * Fri Feb 4 2005 Miloslav Trmac <mitr@redhat.com> - 3.1.0-7
  176. - Rebuild against Python 2.4
  177. * Sun Aug 08 2004 Alan Cox <alan@redhat.com> 3.1.0-6
  178. - Build requires libtool (Steve Grubb)
  179. * Fri Jul 02 2004 Elliot Lee <sopwith@redhat.com> 3.1.0-5
  180. - rebuilt
  181. - Add _smp_mflags
  182. * Wed Mar 24 2004 Jeff Johnson <jbj@redhat.com> 3.1.0-3
  183. - fix: extgcd_w problem fixed by upgrading from CVS.
  184. * Tue Mar 02 2004 Elliot Lee <sopwith@redhat.com>
  185. - rebuilt
  186. * Fri Feb 13 2004 Elliot Lee <sopwith@redhat.com>
  187. - rebuilt
  188. * Mon Dec 22 2003 Jeff Johnson <jbj@jbj.org> 3.1.0-1
  189. - upgrade to 3.1.0.
  190. - recompile against python-2.3.3.
  191. * Mon Jun 30 2003 Jeff Johnson <jbj@redhat.com> 3.0.1-0.20030630
  192. - upstream fixes for DSA and ppc64.
  193. * Mon Jun 23 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-2
  194. - upgrade to 3.0.0 final.
  195. - fix for DSA (actually, modulo inverse) sometimes failing.
  196. * Fri Jun 20 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-1.20030619
  197. - avoid asm borkage on ppc64.
  198. * Thu Jun 19 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-1.20030618
  199. - rebuild for release bump.
  200. * Tue Jun 17 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-1.20030616
  201. - try to out smart libtool a different way.
  202. - use $bc_target_cpu, not $bc_target_arch, to detect /usr/lib64.
  203. * Mon Jun 16 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-1.20030615
  204. - use -mcpu=powerpc64 on ppc64.
  205. * Fri Jun 13 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-1.20030613
  206. - upgrade to latest snapshot.
  207. * Fri Jun 6 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-1.20030605
  208. - rebuild into another tree.
  209. * Wed Jun 04 2003 Elliot Lee <sopwith@redhat.com>
  210. - rebuilt
  211. * Tue Jun 3 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-0.20030603
  212. - update to 3.0.0 snapshot, fix mpmod (and DSA) on 64b platforms.
  213. * Mon Jun 2 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-0.20030602
  214. - update to 3.0.0 snapshot, merge patches, fix gcd rshift and ppc problems.
  215. * Thu May 29 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-0.20030529
  216. - update to 3.0.0 snapshot, fix ia64/x86_64 build problems.
  217. * Wed May 28 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-0.20030528
  218. - upgrade to 3.0.0 snapshot, adding rpm specific base64.[ch] changes.
  219. - add PYTHONPATH=.. so that "make check" can test the just built _bc.so module.
  220. - grab cpuinfo and run "make bench".
  221. - continue ignoring "make check" failures, LD_LIBRARY_PATH needed for _bc.so.
  222. - skip asm build failure on ia64 for now.
  223. - ignore "make bench" exit codes too, x86_64 has AES segfault.
  224. * Wed May 21 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-0.20030521
  225. - upgrade to 3.0.0 snapshot, including python subpackage.
  226. - ignore "make check" failure for now.
  227. * Fri May 16 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-0.20030516
  228. - upgrade to 3.0.0 snapshot, including ia64 and x86_64 fixes.
  229. - add %%check.
  230. - ignore "make check" failure on ia64 for now.
  231. * Mon May 12 2003 Jeff Johnson <jbj@redhat.com> 3.0.0-0.20030512
  232. - upgrade to 3.0.0 snapshot.
  233. - add doxygen doco.
  234. - use /dev/urandom as default entropy source.
  235. - avoid known broken compilation for now.
  236. * Wed Jan 22 2003 Tim Powers <timp@redhat.com>
  237. - rebuilt
  238. * Tue Nov 19 2002 Tim Powers <timp@redhat.com>
  239. - rebuild on all arches
  240. * Fri Aug 2 2002 Jeff Johnson <jbj@redhat.com> 2.2.0-6
  241. - install types.h (#68999).
  242. * Fri Jun 21 2002 Tim Powers <timp@redhat.com>
  243. - automated rebuild
  244. * Wed Jun 5 2002 Jeff Johnson <jbj@redhat.com>
  245. - run ldconfig when installing/erasing (#65974).
  246. * Thu May 23 2002 Tim Powers <timp@redhat.com>
  247. - automated rebuild
  248. * Mon May 13 2002 Jeff Johnson <jbj@redhat.com>
  249. - upgrade to latest 2.2.0 (from cvs.rpm.org).
  250. * Mon Jan 21 2002 Jeff Johnson <jbj@redhat.com>
  251. - use the same beecrypt-2.2.0 that rpm is using internally.
  252. * Thu Jan 10 2002 Nalin Dahyabhai <nalin@redhat.com> 2.1.0-1
  253. - initial package