]> git.pld-linux.org Git - packages/botan.git/commitdiff
- new, based on fedora package
authorElan Ruusamäe <glen@pld-linux.org>
Thu, 1 Sep 2011 10:40:23 +0000 (10:40 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    README.fedora -> 1.1
    botan.spec -> 1.1
    soname.patch -> 1.1

README.fedora [new file with mode: 0644]
botan.spec [new file with mode: 0644]
soname.patch [new file with mode: 0644]

diff --git a/README.fedora b/README.fedora
new file mode 100644 (file)
index 0000000..f3b8795
--- /dev/null
@@ -0,0 +1,14 @@
+For legal reasons, the following modules have been completely removed
+from the Botan package in Fedora:
+
+ * Block Ciphers
+   * IDEA [src/block/idea]
+   * RC6 [src/block/rc6]
+   * RC5 [src/block/rc5]
+ * Public Key Base
+   * ECC Public Key [src/pubkey/ecc_key]
+   * ECC Domain Parameters [src/pubkey/ec_dompar]
+   * ECDSA [src/pubkey/ecdsa]
+   * ECKAEG [src/pubkey/eckaeg]
+ * Math
+   * GF(p) Math [src/math/gfpmath]
diff --git a/botan.spec b/botan.spec
new file mode 100644 (file)
index 0000000..0ba0c79
--- /dev/null
@@ -0,0 +1,150 @@
+#
+# Conditional build:
+%bcond_without tests           # build without tests
+%bcond_without apidocs         # do not build and package API docs
+%bcond_without static_libs     # don't build static libraries
+
+Summary:       Crypto library written in C++
+Name:          botan
+Version:       1.8.13
+Release:       1
+License:       BSD
+Group:         Libraries
+URL:           http://botan.randombit.net/
+# tarfile is stripped using repack.sh. original tarfile to be found
+# here: http://files.randombit.net/botan/Botan-%%{version}.tbz
+Source0:       http://pkgs.fedoraproject.org/repo/pkgs/botan/Botan-%{version}.stripped.tbz/e1cf4c2990a60867603fc111f0715e24/Botan-%{version}.stripped.tbz
+# Source0-md5: e1cf4c2990a60867603fc111f0715e24
+Source1:       README.fedora
+# soname was changed unintentionally upstream, revert it.
+Patch0:                soname.patch
+BuildRequires: bzip2-devel
+BuildRequires: gmp-devel
+BuildRequires: libstdc++-devel
+BuildRequires: openssl-devel
+BuildRequires: python
+BuildRequires: zlib-devel
+BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+Botan is a BSD-licensed crypto library written in C++. It provides a
+wide variety of basic cryptographic algorithms, X.509 certificates and
+CRLs, PKCS \#10 certificate requests, a filter/pipe message processing
+system, and a wide variety of other features, all written in portable
+C++. The API reference, tutorial, and examples may help impart the
+flavor of the library.
+
+%package devel
+Summary:       Development files for botan
+Group:         Development/Libraries
+Requires:      %{name} = %{version}-%{release}
+Requires:      bzip2-devel
+Requires:      gmp-devel
+Requires:      openssl-devel
+Requires:      pkgconfig
+Requires:      zlib-devel
+
+%description devel
+This package contains libraries and header files for developing
+applications that use botan.
+
+%package static
+Summary:       Static botan library
+Summary(pl.UTF-8):     Statyczna biblioteka botan
+Group:         Development/Libraries
+Requires:      %{name}-devel = %{version}-%{release}
+
+%description static
+Static botan library.
+
+%description static -l pl.UTF-8
+Statyczna biblioteka botan.
+
+%package apidocs
+Summary:       botan API documentation
+Summary(pl.UTF-8):     Dokumentacja API biblioteki botan
+Group:         Documentation
+
+%description apidocs
+API and internal documentation for botan library.
+
+%description apidocs -l pl.UTF-8
+Dokumentacja API biblioteki botan.
+
+%prep
+%setup -q -n Botan-%{version}
+%patch0 -p0
+cp -p %{SOURCE1} .
+
+%build
+# we have the necessary prerequisites, so enable optional modules
+%define enable_modules gnump,bzip2,zlib,openssl
+
+# fixme: maybe disable unix_procs, very slow.
+%define disable_modules %{nil}
+
+./configure.py \
+       --prefix=%{_prefix} \
+       --libdir=%{_lib} \
+       --cc=gcc \
+       --os=linux \
+       --cpu=%{_arch} \
+       --enable-modules=%{enable_modules} \
+       --disable-modules=%{disable_modules}
+
+# (ab)using CXX as an easy way to inject our CXXFLAGS
+%{__make} \
+       CXX="%{__cxx} %{rpmcxxflags}"
+
+%if %{with tests}
+%{__make} \
+       CXX="%{__cxx} %{rpmcxxflags}" check
+
+# these checks would fail
+mv checks/validate.dat{,.orig}
+awk '/\[.*\]/{f=0} /\[(RC5.*|RC6|IDEA)\]/{f=1} (f && !/^#/){sub(/^/,"#")} {print}' \
+       checks/validate.dat.orig > checks/validate.dat
+LD_LIBRARY_PATH=. ./check --validate
+%endif
+
+%install
+rm -rf $RPM_BUILD_ROOT
+%{__make} install \
+       INSTALL_CMD_EXEC="install -p -m 755" \
+       INSTALL_CMD_DATA="install -p -m 644" \
+       DOCDIR=_doc \
+       DESTDIR=$RPM_BUILD_ROOT%{_prefix}
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+# not packaging shared lib properly, so no ldconfig needed
+#%post -p /sbin/ldconfig
+#%postun       -p /sbin/ldconfig
+
+%files
+%defattr(644,root,root,755)
+%doc _doc/readme.txt _doc/log.txt _doc/thanks.txt _doc/credits.txt
+%doc _doc/license.txt _doc/fips140.tex _doc/pgpkeys.asc
+%doc README.fedora
+%attr(755,root,root) %{_libdir}/libbotan-1.8.*.so
+
+%files devel
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_bindir}/botan-config
+%{_includedir}/botan
+%{_libdir}/libbotan.so
+%{_pkgconfigdir}/botan-1.8.pc
+
+%if %{with static_libs}
+%files static
+%defattr(644,root,root,755)
+%{_libdir}/libbotan.a
+%endif
+
+%if %{with apidocs}
+%files apidocs
+%defattr(644,root,root,755)
+%doc doc/examples
+%doc _doc/api* _doc/tutorial*
+%endif
diff --git a/soname.patch b/soname.patch
new file mode 100644 (file)
index 0000000..fd21e6b
--- /dev/null
@@ -0,0 +1,12 @@
+============================================================
+--- configure.py        56ef9e873a4807c437f22b0ab58a22987e6ab2f9
++++ configure.py        3cdef18138198b63b180b200ea521140b161ffcc
+@@ -38,7 +38,7 @@ class BuildConfigurationInformation(obje
+     version_major = 1
+     version_minor = 8
+     version_patch = 13
+-    version_so_patch = 13
++    version_so_patch = 2
+     version_suffix = ''
+     version_string = '%d.%d.%d%s' % (
This page took 0.21081 seconds and 4 git commands to generate.