1 |
< |
### RPM external openssl 0.9.7d |
2 |
< |
Source: http://www.openssl.org/source/%n-%v.tar.gz |
3 |
< |
Requires: perl |
1 |
> |
### RPM external openssl 0.9.8e |
2 |
> |
Source: http://cmsrep.cern.ch/cmssw/openssl-sources/%n-fips-%realversion-usa.tar.bz2 |
3 |
> |
Patch0: openssl-0.9.8e-rh-0.9.8e-12.el5_4.6 |
4 |
> |
Patch1: openssl-x86-64-gcc420 |
5 |
> |
|
6 |
> |
%prep |
7 |
> |
%setup -n %n-fips-%{realversion} |
8 |
> |
%patch0 -p1 |
9 |
> |
%patch1 -p1 |
10 |
|
|
11 |
|
%build |
12 |
< |
./config --prefix=%i shared |
12 |
> |
# Looks like rpmbuild passes its own sets of flags via the |
13 |
> |
# RPM_OPT_FLAGS environment variable and those flags include |
14 |
> |
# -m64 (probably since rpmbuild processor detection is not |
15 |
> |
# fooled by linux32). A quick fix is to just set the variable |
16 |
> |
# to "" but we should probably understand how rpm determines |
17 |
> |
# those flags and use them for our own good. |
18 |
> |
export RPM_OPT_FLAGS="-O2 -fPIC -g -pipe -Wall -Wa,--noexecstack -fno-strict-aliasing -Wp,-DOPENSSL_USE_NEW_FUNCTIONS -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -mtune=generic" |
19 |
> |
|
20 |
> |
cfg_opts="no-idea no-mdc2 no-rc5 no-ec no-ecdh no-ecdsa shared fipscanisterbuild" |
21 |
> |
|
22 |
> |
case %cmsplatf in |
23 |
> |
osx*) |
24 |
> |
perl -p -i -e 's|-compatibility_version.*|-compatibility_version \${SHLIB_MAJOR}.\${SHLIB_MINOR} \\|' Makefile.ssl |
25 |
> |
cfg_args="-DOPENSSL_USE_NEW_FUNCTIONS" |
26 |
> |
;; |
27 |
> |
*) |
28 |
> |
cfg_args="fipscanisterbuild" |
29 |
> |
;; |
30 |
> |
esac |
31 |
> |
|
32 |
> |
./config --prefix=%i $cfg_args enable-seed enable-tlsext enable-rfc3779 no-asm \ |
33 |
> |
no-idea no-mdc2 no-rc5 no-ec no-ecdh no-ecdsa shared |
34 |
> |
|
35 |
|
make |
36 |
|
%install |
37 |
+ |
export RPM_OPT_FLAGS="-O2 -fPIC -g -pipe -Wall -Wa,--noexecstack -fno-strict-aliasing -Wp,-DOPENSSL_USE_NEW_FUNCTIONS -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -mtune=generic" |
38 |
|
make install |
39 |
+ |
rm -rf %{i}/lib/pkgconfig |
40 |
+ |
|
41 |
+ |
# MacOSX is case insensitive and the man page structure has case sensitive logic |
42 |
+ |
case %cmsplatf in |
43 |
+ |
osx* ) |
44 |
+ |
rm -rf %{i}/ssl/man |
45 |
+ |
;; |
46 |
+ |
esac |
47 |
|
perl -p -i -e "s|^#!.*perl|#!/usr/bin/env perl|" %{i}/ssl/misc/CA.pl %{i}/ssl/misc/der_chop %{i}/bin/c_rehash |
48 |
+ |
|