]> git.pld-linux.org Git - packages/openssl.git/blob - openssl.spec
- 0.9.6b - security and bug fixes release
[packages/openssl.git] / openssl.spec
1 %include        /usr/lib/rpm/macros.perl
2 Summary:        OpenSSL Toolkit libraries for the "Secure Sockets Layer" (SSL v2/v3)
3 Summary(de):    Secure Sockets Layer (SSL)-Kommunikationslibrary
4 Summary(fr):    Utilitaires de communication SSL (Secure Sockets Layer)
5 Name:           openssl
6 Version:        0.9.6b
7 Release:        1
8 License:        Apache-style License
9 Vendor:         The OpenSSL Project
10 Group:          Libraries
11 Group(de):      Libraries
12 Group(es):      Bibliotecas
13 Group(fr):      Librairies
14 Group(pl):      Biblioteki
15 Source0:        ftp://ftp.openssl.org/source/%{name}-%{version}.tar.gz
16 Patch0:         %{name}-alpha-ccc.patch
17 # patch1 is only for 0.9.6a version. This version isn't binary
18 # compatibile with 0.9.6 but have this same soname.
19 Patch1:         %{name}-soname.patch
20 Patch2:         %{name}-optflags.patch
21 BuildRequires:  perl-devel >= 5.6.1
22 BuildRequires:  textutils
23 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
24 Obsoletes:      SSLeay
25 Obsoletes:      SSLeay-devel
26 Obsoletes:      SSLeay-perl
27
28 %description
29 The OpenSSL Project is a collaborative effort to develop a robust,
30 commercial-grade, full-featured, and Open Source toolkit implementing
31 the Secure Sockets Layer (SSL v2/v3) and Transport Layer Security (TLS
32 v1) protocols with full-strength cryptography world-wide. The project
33 is managed by a worldwide community of volunteers that use the
34 Internet to communicate, plan, and develop the OpenSSL tookit and its
35 related documentation.
36
37 OpenSSL is based on the excellent SSLeay library developed by Eric A.
38 Young and Tim J. Hudson. The OpenSSL toolkit is licensed under an
39 Apache-style licence, which basically means that you are free to get
40 and use it for commercial and non-commercial purposes subject to some
41 simple license conditions.
42
43 This package contains shared libraries only, install openssl-tools if
44 you want to use openssl cmdline tool.
45
46 %description -l de
47 Openssl enthält das OpenSSL Zertifikatsmanagementtool und shared
48 libraries, die verschiedene Verschlüsselungs- und
49 Entschlüsselungsalgorithmen und
50 - -protokolle, wie DES, RC4, RSA und SSL zur Verfügung stellen.
51
52 %description -l fr
53 OpenSSL est un outiil de gestion des certificats et les librairies
54 partagees qui fournit plusieurs protocoles et algorithmes de
55 codage/decodage, incluant DES, RC4, RSA et SSL.
56
57 %package tools
58 Summary:        OpenSSL command line tool and utilities
59 Group:          Applications/Communications
60 Group(de):      Applikationen/Kommunikation
61 Group(pl):      Aplikacje/Komunikacja
62 Requires:       %{name} = %{version}
63
64 %description tools
65 The OpenSSL Toolkit cmdline tool openssl and utility scripts.
66
67 %package tools-perl
68 Summary:        OpenSSL utilities written in Perl
69 Group:          Applications/Communications
70 Group(de):      Applikationen/Kommunikation
71 Group(fr):      Utilitaires
72 Group(pl):      Aplikacje/Komunikacja
73 Requires:       %{name} = %{version}
74
75 %description tools-perl
76 OpenSSL Toolkit tools written in Perl.
77
78 %package devel
79 Summary:        Development part of OpenSSL Toolkit libraries
80 Summary(de):    Secure Sockets Layer Kommunikationslibrary: statische libraries+header
81 Summary(fr):    Librairies statiques, headers et utilitaires pour communication SSL
82 Summary(pl):    Czê¶æ bibiloteki OpenSSL przeznaczona dla programistów
83 Group:          Development/Libraries
84 Group(de):      Entwicklung/Libraries
85 Group(fr):      Development/Librairies
86 Group(pl):      Programowanie/Biblioteki
87 Requires:       %{name} = %{version}
88
89 %description devel
90 Development part of OpenSSL library.
91
92 %description devel -l pl
93 Czê¶æ bibiloteki OpenSSL przeznaczona dla programistów.
94
95 %package static
96 Summary:        Static OpenSSL libraries
97 Summary(pl):    Statyczne wersje bibliotek z OpenSSL
98 Group:          Development/Libraries
99 Group(de):      Entwicklung/Libraries
100 Group(fr):      Development/Librairies
101 Group(pl):      Programowanie/Biblioteki
102 Requires:       %{name}-devel = %{version}
103
104 %description static
105 Static OpenSSL Toolkit libraries.
106
107 %description static -l pl
108 Statyczne wersje bibliotek z OpenSSL.
109
110 %prep
111 %setup -q 
112 %patch0 -p1
113 %patch1 -p1
114 %patch2 -p1
115
116 %build
117 for f in ` grep -r "/usr/local/bin/perl" . | cut -d":" -f1`; do
118         perl -pi -e 's#/usr/local/bin/perl#%{_bindir}/perl#g' $f
119 done
120
121 touch Makefile.*
122
123 perl util/perlpath.pl %{_bindir}/perl
124
125 OPTFLAGS="%{rpmcflags}"
126 export OPTFLAGS
127 %ifarch i386 i486
128 ./Configure --openssldir=%{_var}/lib/%{name} linux-elf shared 386
129 %endif
130 %ifarch i586 i686
131 ./Configure --openssldir=%{_var}/lib/%{name} linux-elf shared
132 %endif
133 %ifarch ppc
134 ./Configure --openssldir=%{_var}/lib/%{name} linux-ppc shared
135 %endif
136 %ifarch alpha
137 ./Configure --openssldir=%{_var}/lib/%{name} threads linux-alpha+bwx-gcc shared
138 %endif
139 %ifarch sparc
140 ./Configure --openssldir=%{_var}/lib/%{name} threads linux-sparcv8 shared
141 %endif
142
143 %{__make}
144 %{__make} rehash
145
146 # Conv PODs to man pages. "openssl_" prefix is added to each manpage 
147 # to avoid potential conflicts with others packages.
148 center="OpenSSL 0.9.6"
149 rel="OpenSSL 0.9.6"
150
151 cd doc/apps || exit 1 
152 perl -pi -e 's/(\W)((?<!openssl_)\w+)(\(\d\))/$1openssl_$2$3/g; s/openssl_openssl/openssl/g;' *.pod;
153
154 for pod in *.pod; do 
155     if [ $pod != "openssl.pod" ]; then
156         mv -f $pod openssl_$pod;
157         pod=openssl_$pod;
158     fi
159
160     sec=1
161     if [ $pod = "openssl_config.pod" ]; then
162         sec=5
163     fi
164
165     manpage=`basename $pod .pod`.$sec;      
166     pod2man --section="$sec" --release="$rel" --center="$center" \
167             $pod > $manpage;
168     echo "$manpage";
169 done
170 cd ..
171
172 sec=3
173 for dir in ssl crypto; do 
174         cd $dir || exit 1;
175         if [ $dir = "ssl" ]; then
176                 rel="OpenSSL SSL/TLS library"
177         elif [ $dir = "crypto" ]; then 
178                 rel="OpenSSL cryptographic library"
179         fi
180         
181         perl -p -i -e 's/(\W)((?<!openssl_)\w+)(\(\d\))/$1openssl_$2$3/g; s/openssl_openssl/openssl/g;' *.pod;
182         
183         for pod in *.pod; do 
184             sec=`[ "$pod" = "des_modes.pod" ] && echo 7 || echo 3`;     
185             mv -f $pod openssl_$pod;
186             pod=openssl_$pod;
187             manpage=`basename $pod .pod`.$sec;
188             pod2man --section="$sec" --release="$rel" --center=" " $pod > $manpage;
189             echo "$manpage";
190         done
191         cd ..
192 done
193
194 #cd perl
195 #perl Makefile.PL
196 #make
197
198 %install
199 rm -rf $RPM_BUILD_ROOT
200 install -d $RPM_BUILD_ROOT{%{_sysconfdir}/%{name},%{_libdir}/%{name}} \
201            $RPM_BUILD_ROOT%{_mandir}/man{1,3,5,7}
202
203 %{__make} install \
204         INSTALLTOP=%{_prefix} \
205         INSTALL_PREFIX=$RPM_BUILD_ROOT
206
207 install libRSAglue.a libcrypto.a libssl.a       $RPM_BUILD_ROOT%{_libdir}
208 install lib*.so.*.*     $RPM_BUILD_ROOT%{_libdir}
209 ln -sf libcrypto.so.*.* $RPM_BUILD_ROOT%{_libdir}/libcrypto.so
210 ln -sf libssl.so.*.* $RPM_BUILD_ROOT%{_libdir}/libssl.so
211
212 mv -f $RPM_BUILD_ROOT%{_var}/lib/%{name}/openssl.cnf $RPM_BUILD_ROOT%{_sysconfdir}/%{name}
213 ln -s %{_sysconfdir}/%{name}/openssl.cnf \
214         $RPM_BUILD_ROOT%{_var}/lib/%{name}/%{name}.cnf
215
216 mv -f $RPM_BUILD_ROOT%{_var}/lib/%{name}/misc/*  $RPM_BUILD_ROOT%{_libdir}/%{name}
217 rm -rf $RPM_BUILD_ROOT%{_var}/lib/%{name}/misc
218
219 mv -f $RPM_BUILD_ROOT%{_bindir}/c_rehash $RPM_BUILD_ROOT%{_libdir}/%{name}
220
221 find $RPM_BUILD_ROOT%{_mandir} -type f | xargs rm -f
222 install doc/apps/*.1 $RPM_BUILD_ROOT%{_mandir}/man1
223 install doc/apps/*.5 $RPM_BUILD_ROOT%{_mandir}/man5
224 install doc/ssl/*.3 doc/crypto/*.3 $RPM_BUILD_ROOT%{_mandir}/man3
225 install doc/crypto/*.7 $RPM_BUILD_ROOT%{_mandir}/man7
226
227 gzip -9nf CHANGES CHANGES.SSLeay LICENSE NEWS README doc/*.txt
228
229 %post   -p /sbin/ldconfig
230 %postun -p /sbin/ldconfig
231
232 %clean
233 rm -rf $RPM_BUILD_ROOT
234
235 %files
236 %defattr(644,root,root,755)
237 %attr(755,root,root) %{_libdir}/lib*.so.*.*
238 %doc {CHANGES,CHANGES.SSLeay,LICENSE,NEWS,README}.gz
239 %doc doc/*.txt.gz doc/openssl_button.gif doc/openssl_button.html
240
241 %files tools
242 %defattr(644,root,root,755)
243 %dir %{_sysconfdir}/%{name}
244 %dir %{_var}/lib/%{name}
245 %dir %{_var}/lib/%{name}/private
246 %dir %{_var}/lib/%{name}/certs
247 %verify(not md5 size mtime) %config(noreplace) %{_sysconfdir}/%{name}/openssl.cnf
248 %verify(not md5 size mtime) %config(noreplace) %{_var}/lib/%{name}/openssl.cnf
249
250 %attr(755,root,root) %{_bindir}/%{name}
251 %dir %{_libdir}/%{name}
252 %attr(755,root,root) %{_libdir}/%{name}/CA.sh
253 %attr(755,root,root) %{_libdir}/%{name}/c_hash
254 %attr(755,root,root) %{_libdir}/%{name}/c_info
255 %attr(755,root,root) %{_libdir}/%{name}/c_issuer
256 %attr(755,root,root) %{_libdir}/%{name}/c_name
257
258 %{_mandir}/man1/openssl.1*
259 %{_mandir}/man1/openssl_asn1parse.1*
260 %{_mandir}/man1/openssl_ca.1*
261 %{_mandir}/man1/openssl_ciphers.1*
262 %{_mandir}/man1/openssl_crl.1*
263 %{_mandir}/man1/openssl_crl2pkcs7.1*
264 %{_mandir}/man1/openssl_dgst.1*
265 %{_mandir}/man1/openssl_dhparam.1*
266 %{_mandir}/man1/openssl_dsa.1*
267 %{_mandir}/man1/openssl_dsaparam.1*
268 %{_mandir}/man1/openssl_enc.1*
269 %{_mandir}/man1/openssl_gendsa.1*
270 %{_mandir}/man1/openssl_genrsa.1*
271 %{_mandir}/man1/openssl_nseq.1*
272 %{_mandir}/man1/openssl_passwd.1*
273 %{_mandir}/man1/openssl_pkcs12.1*
274 %{_mandir}/man1/openssl_pkcs7.1*
275 %{_mandir}/man1/openssl_pkcs8.1*
276 %{_mandir}/man1/openssl_rand.1*
277 %{_mandir}/man1/openssl_req.1*
278 %{_mandir}/man1/openssl_rsa.1*
279 %{_mandir}/man1/openssl_s_client.1*
280 %{_mandir}/man1/openssl_s_server.1*
281 %{_mandir}/man1/openssl_sess_id.1*
282 %{_mandir}/man1/openssl_smime.1*
283 %{_mandir}/man1/openssl_speed.1*
284 %{_mandir}/man1/openssl_spkac.1*
285 %{_mandir}/man1/openssl_verify.1*
286 %{_mandir}/man1/openssl_version.1*
287 %{_mandir}/man1/openssl_x509.1*
288 %{_mandir}/man5/*.5*
289
290 %files tools-perl
291 %defattr(644,root,root,755)
292 %attr(755,root,root) %{_libdir}/%{name}/CA.pl
293 %attr(755,root,root) %{_libdir}/%{name}/der_chop
294 %attr(755,root,root) %{_libdir}/%{name}/c_rehash
295 %{_mandir}/man1/openssl_CA.pl.1*
296
297 %files devel
298 %defattr(644,root,root,755)
299 %attr(755,root,root) %{_libdir}/lib*.so
300 %{_includedir}/%{name}
301 %{_mandir}/man3/*.3*
302
303 %files static
304 %defattr(644,root,root,755)
305 %{_libdir}/lib*.a
This page took 0.055621 seconds and 4 git commands to generate.