gcrypt/gcrypt.spec

changeset 107
2f8ffdf7658b
parent 106
5e7005042079
child 284
33c60a6d7034
equal deleted inserted replaced
0:127305fe1b16 1:f8f3a11ece2b
30 Distribution: OpenPKG Community 30 Distribution: OpenPKG Community
31 Class: PLUS 31 Class: PLUS
32 Group: Cryptography 32 Group: Cryptography
33 License: LGPL 33 License: LGPL
34 Version: 1.4.3 34 Version: 1.4.3
35 Release: 20080921 35 Release: 20090106
36
37 # package options
38 %option with_idea no
36 39
37 # list of sources 40 # list of sources
38 Source0: ftp://ftp.gnupg.org/gcrypt/libgcrypt/libgcrypt-%{version}.tar.gz 41 Source0: ftp://ftp.gnupg.org/gcrypt/libgcrypt/libgcrypt-%{version}.tar.gz
42 Source1: idea.c
43 Patch0: gcrypt.patch
39 44
40 # build information 45 # build information
41 Prefix: %{l_prefix} 46 Prefix: %{l_prefix}
42 BuildRoot: %{l_buildroot} 47 BuildRoot: %{l_buildroot}
43 BuildPreReq: OpenPKG, openpkg >= 20040130, gpg-error, make, gcc 48 BuildPreReq: OpenPKG, openpkg >= 20040130, gpg-error, make, gcc
55 regex = libgcrypt-(__VER__)\.tar\.gz 60 regex = libgcrypt-(__VER__)\.tar\.gz
56 } 61 }
57 62
58 %prep 63 %prep
59 %setup -q -n libgcrypt-%{version} 64 %setup -q -n libgcrypt-%{version}
65 %patch -p0
66 %if "%{with_idea}" == "yes"
67 echo $PWD
68 pwd
69 echo `pwd`
70 cp %{SOURCE idea.c} cipher/
71 %{l_shtool} subst \
72 -e 's;^\(EXTRA_libcipher_la_SOURCES =\);\1 idea.c;' \
73 -e 's;^\(GCRYPT_MODULES = .*[^\ \t]\)[\ \t]*$;\1 idea.lo;' \
74 -e 's;^\(GCRYPT_CIPHERS = .*[^\ \t]\)[\ \t]*$;\1 idea.lo;' \
75 -e 's;^\(LIBGCRYPT_CIPHERS = .*[^\ \t]\)[\ \t]*$;\1 idea;' \
76 cipher/Makefile.in
77 %{l_shtool} subst \
78 -e 's;^\(available_ciphers="arcfour [^"][^"]*\)";\1 idea";' \
79 configure
80 %endif
60 81
61 %build 82 %build
62 ( echo "ac_cv_lib_pthread_pthread_create=no" 83 ( echo "ac_cv_lib_pthread_pthread_create=no"
63 echo "ac_cv_lib_pth_pth_version=no" 84 echo "ac_cv_lib_pth_pth_version=no"
64 ) >config.cache 85 ) >config.cache
65 CC="%{l_cc}" \ 86 CC="%{l_cc}" \
66 CFLAGS="%{l_cflags -O}" \ 87 CFLAGS="%{l_cflags -O}" \
88 %if "%{with_idea}" == "yes"
89 CPPFLAGS="-DUSE_IDEA $CPPFLAGS" \
90 %endif
67 GREP="grep" \ 91 GREP="grep" \
68 ./configure \ 92 ./configure \
69 --cache-file=./config.cache \ 93 --cache-file=./config.cache \
70 --prefix=%{l_prefix} \ 94 --prefix=%{l_prefix} \
71 --mandir=%{l_prefix}/man \ 95 --mandir=%{l_prefix}/man \

mercurial