2 changed files with 138 additions and 0 deletions
@ -0,0 +1,36 @@
|
||||
Index: src/build-data/cc/gcc.txt
|
||||
--- src/build-data/cc/gcc.txt.orig 2010-08-31 18:39:00.000000000 +0200
|
||||
+++ src/build-data/cc/gcc.txt 2010-10-30 11:41:02.000000000 +0200
|
||||
@@ -11,7 +11,7 @@
|
||||
add_lib_option "-l"
|
||||
|
||||
lang_flags "-D_REENTRANT -Wno-long-long"
|
||||
-warning_flags "-W -Wall"
|
||||
+warning_flags ""
|
||||
#warning_flags "-Wextra -Wall -Wstrict-aliasing -Wstrict-overflow=5 -Wcast-align -Wmissing-declarations -Wno-unused-parameter"
|
||||
|
||||
lib_opt_flags "-O2 -finline-functions"
|
||||
Index: src/build-data/makefile/unix.in
|
||||
--- src/build-data/makefile/unix.in.orig 2010-08-31 18:39:00.000000000 +0200
|
||||
+++ src/build-data/makefile/unix.in 2010-10-30 11:41:18.000000000 +0200
|
||||
@@ -22,7 +22,7 @@
|
||||
BINDIR = $(DESTDIR)/bin
|
||||
LIBDIR = $(DESTDIR)/%{libdir}
|
||||
HEADERDIR = $(DESTDIR)/%{includedir}/botan
|
||||
-DOCDIR = $(DESTDIR)/%{docdir}/Botan-$(VERSION)
|
||||
+DOCDIR = $(DESTDIR)/%{docdir}
|
||||
PKGCONF_DIR = $(LIBDIR)/pkgconfig
|
||||
|
||||
CONFIG_SCRIPT = %{botan_config}
|
||||
Index: src/utils/types.h
|
||||
--- src/utils/types.h.orig 2010-08-31 18:39:01.000000000 +0200
|
||||
+++ src/utils/types.h 2010-10-30 11:40:33.000000000 +0200
|
||||
@@ -22,7 +22,7 @@
|
||||
typedef unsigned __int64 u64bit;
|
||||
#elif defined(__KCC)
|
||||
typedef unsigned __long_long u64bit;
|
||||
-#elif defined(__GNUG__)
|
||||
+#elif defined(__GNUC__)
|
||||
__extension__ typedef unsigned long long u64bit;
|
||||
#else
|
||||
typedef unsigned long long u64bit;
|
||||
@ -0,0 +1,102 @@
|
||||
## |
||||
## botan18.spec -- OpenPKG RPM Package Specification |
||||
## Copyright (c) 2000-2010 OpenPKG Foundation e.V. <http://openpkg.net/> |
||||
## |
||||
## Permission to use, copy, modify, and distribute this software for |
||||
## any purpose with or without fee is hereby granted, provided that |
||||
## the above copyright notice and this permission notice appear in all |
||||
## copies. |
||||
## |
||||
## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED |
||||
## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF |
||||
## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. |
||||
## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR |
||||
## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
||||
## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT |
||||
## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF |
||||
## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND |
||||
## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, |
||||
## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT |
||||
## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF |
||||
## SUCH DAMAGE. |
||||
## |
||||
|
||||
# package version |
||||
%define V_major 1.8 |
||||
%define V_minor 10 |
||||
|
||||
# package information |
||||
Name: botan18 |
||||
Summary: C++ Cryptography Library |
||||
URL: http://botan.randombit.net/ |
||||
Vendor: The Botan Project |
||||
Packager: OpenPKG Foundation e.V. |
||||
Distribution: OpenPKG Community |
||||
Class: EVAL |
||||
Group: Cryptography |
||||
License: BSD |
||||
Version: %{V_major}.%{V_minor} |
||||
Release: 20101030 |
||||
|
||||
# list of sources |
||||
Source0: http://files.randombit.net/botan/v%{V_major}/Botan-%{version}.tgz |
||||
Patch0: botan18.patch |
||||
|
||||
# build information |
||||
BuildPreReq: OpenPKG, openpkg >= 20100101, gcc, gcc::with_cxx = yes, python, perl |
||||
PreReq: OpenPKG, openpkg >= 20100101 |
||||
|
||||
%description |
||||
Botan is a C++ cryptography library, providing a wide variety of |
||||
cryptographic algorithms, formats, and protocols. |
||||
|
||||
%track |
||||
prog botan = { |
||||
version = %{version} |
||||
url = http://botan.randombit.net/download.html |
||||
regex = Botan-(\d+\.\d?[0248]\.\d+)\.tgz |
||||
} |
||||
|
||||
%prep |
||||
%setup -q -n Botan-%{version} |
||||
%patch -p0 |
||||
|
||||
%build |
||||
perl -p -i.bak -e \ |
||||
's;(0x[\da-fA-F]{16});\1ULL;g' \ |
||||
src/*/*.cpp |
||||
rm -f src/*.bak |
||||
%{l_shtool} subst \ |
||||
-e 's;-mcpu=;-mtune=;g' \ |
||||
src/build-data/cc/gcc.txt |
||||
CC="gcc" \ |
||||
python ./configure.py \ |
||||
--prefix=%{l_prefix} \ |
||||
--includedir=%{l_prefix}/include/botan18 \ |
||||
--docdir=share/botan18 \ |
||||
--disable-shared |
||||
%{l_make} %{l_mflags -O} |
||||
|
||||
%install |
||||
%{l_make} %{l_mflags} install \ |
||||
DESTDIR=$RPM_BUILD_ROOT%{l_prefix} \ |
||||
OWNER=`%{l_shtool} echo -e '%u'` \ |
||||
GROUP=`%{l_shtool} echo -e '%g'` |
||||
mv $RPM_BUILD_ROOT%{l_prefix}/bin/botan-config \ |
||||
$RPM_BUILD_ROOT%{l_prefix}/bin/botan18-config |
||||
mv $RPM_BUILD_ROOT%{l_prefix}/lib/libbotan.a \ |
||||
$RPM_BUILD_ROOT%{l_prefix}/lib/libbotan18.a |
||||
%{l_shtool} subst \ |
||||
-e 's;-lbotan;-lbotan18;g' \ |
||||
$RPM_BUILD_ROOT%{l_prefix}/bin/botan18-config |
||||
rm -f $RPM_BUILD_ROOT%{l_prefix}/share/botan18/*.txt |
||||
rm -f $RPM_BUILD_ROOT%{l_prefix}/share/botan18/*.tex |
||||
rm -f $RPM_BUILD_ROOT%{l_prefix}/share/botan18/*.asc |
||||
%{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \ |
||||
%{l_files_std} \ |
||||
'%doc %{l_prefix}/share/botan18/*.pdf' |
||||
|
||||
%files -f files |
||||
|
||||
%clean |
||||
|
||||
Loading…
Reference in new issue