]>
Commit | Line | Data |
---|---|---|
8d1548f6 | 1 | %define foover %(echo %{version} | tr . _) |
e043961c | 2 | Summary: NSS - Network Security Services |
900f3743 | 3 | Summary(pl.UTF-8): NSS - Network Security Services |
e043961c | 4 | Name: nss |
90ae5649 | 5 | Version: 3.14.3 |
2455c084 | 6 | Release: 1 |
c61925df | 7 | Epoch: 1 |
c9f1afae | 8 | License: MPL v1.1 or GPL v2+ or LGPL v2.1+ |
a20334db | 9 | Group: Libraries |
de78c6c4 JB |
10 | # :pserver:anonymous@cvs-mirror.mozilla.org:/cvsroot mozilla/dbm -r DBM_1_61_RTM |
11 | # :pserver:anonymous@cvs-mirror.mozilla.org:/cvsroot mozilla/security/dbm -r DBM_1_61_RTM | |
12 | # :pserver:anonymous@cvs-mirror.mozilla.org:/cvsroot mozilla/security/coreconf -r NSS_3_9_4_RTM | |
13 | # :pserver:anonymous@cvs-mirror.mozilla.org:/cvsroot mozilla/security/nss -r NSS_3_9_4_RTM | |
1a10ee06 | 14 | #Source0: %{name}-%{version}.tar.bz2 |
d6727b26 | 15 | Source0: http://ftp.mozilla.org/pub/mozilla.org/security/nss/releases/NSS_%{foover}_RTM/src/%{name}-%{version}.tar.gz |
90ae5649 | 16 | # Source0-md5: b326c2be8df277f62fb9c65fb3428148 |
9e8d6618 | 17 | Source1: %{name}-mozilla-nss.pc |
8d1548f6 | 18 | Source2: %{name}-config.in |
867c7e33 ER |
19 | Source3: http://www.cacert.org/certs/root.der |
20 | # Source3-md5: a61b375e390d9c3654eebd2031461f6b | |
e043961c | 21 | Patch0: %{name}-Makefile.patch |
0c7a986a | 22 | URL: http://www.mozilla.org/projects/security/pki/nss/ |
58a19c98 | 23 | BuildRequires: nspr-devel >= 1:4.9 |
867c7e33 | 24 | BuildRequires: nss-tools |
acc47f6e | 25 | BuildRequires: perl-base |
0e541f12 | 26 | BuildRequires: sqlite3-devel |
e814da19 | 27 | BuildRequires: zlib-devel |
7d80b913 | 28 | BuildConflicts: mozilla < 0.9.6-3 |
58a19c98 | 29 | Requires: nspr >= 1:4.9 |
ce0a2a28 | 30 | Requires: %{name}-softokn-freebl = %{epoch}:%{version}-%{release} |
64c1d08d | 31 | Obsoletes: libnss3 |
8a057a22 | 32 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
e043961c | 33 | |
f68ec3a2 | 34 | %define specflags -fno-strict-aliasing |
c9f1afae JB |
35 | # signed - stripped before signing |
36 | %define _noautostrip .*%{_libdir}/libfreebl3.so\\|.*%{_libdir}/libsoftokn3.so | |
37 | %define _noautochrpath .*%{_libdir}/libfreebl3.so\\|.*%{_libdir}/libsoftokn3.so | |
f68ec3a2 | 38 | |
e3f4677f | 39 | %description |
6b813326 | 40 | NSS supports cross-platform development of security-enabled server |
d8ef6ecb | 41 | applications. Applications built with NSS can support PKCS #5, |
bf42a3ba | 42 | PKCS #7, PKCS #11, PKCS #12, S/MIME, TLS, SSL v2 and v3, X.509 v3 |
6b813326 | 43 | certificates, and other security standards. |
e043961c | 44 | |
238a25a0 JR |
45 | %description -l pl.UTF-8 |
46 | NSS wspomaga pisanie wieloplatformowych bezpiecznych serwerów. | |
47 | Aplikacja używająca NSS jest w stanie obsłużyć PKCS #5, PKCS #7, | |
d8ef6ecb | 48 | PKCS #11, PKCS #12, S/MIME, TLS, SSL v2 oraz v3, certyfikaty X.509 v3, |
238a25a0 | 49 | i wiele innych bezpiecznych standardów. |
e043961c | 50 | |
c3d988d0 JB |
51 | %package tools |
52 | Summary: NSS command line tools and utilities | |
c9f1afae | 53 | Summary(pl.UTF-8): Narzędzia NSS obsługiwane z linii poleceń |
c3d988d0 | 54 | Group: Applications |
93f17fb4 | 55 | Requires: %{name} = %{epoch}:%{version}-%{release} |
c3d988d0 JB |
56 | |
57 | %description tools | |
58 | The NSS Toolkit command line tool. | |
59 | ||
238a25a0 JR |
60 | %description tools -l pl.UTF-8 |
61 | Narzędzia NSS obsługiwane z linii poleceń. | |
c3d988d0 | 62 | |
e043961c | 63 | %package devel |
64 | Summary: NSS - header files | |
900f3743 | 65 | Summary(pl.UTF-8): NSS - pliki nagłówkowe |
e043961c | 66 | Group: Development/Libraries |
93f17fb4 | 67 | Requires: %{name} = %{epoch}:%{version}-%{release} |
58a19c98 | 68 | Requires: nspr-devel >= 1:4.9 |
64c1d08d | 69 | Obsoletes: libnss3-devel |
e043961c | 70 | |
71 | %description devel | |
72 | Development part of NSS library. | |
73 | ||
238a25a0 JR |
74 | %description devel -l pl.UTF-8 |
75 | Część biblioteki NSS przeznaczona dla programistów. | |
e043961c | 76 | |
e043961c | 77 | %package static |
78 | Summary: NSS - static library | |
900f3743 | 79 | Summary(pl.UTF-8): NSS - biblioteka statyczna |
e043961c | 80 | Group: Development/Libraries |
93f17fb4 | 81 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} |
e043961c | 82 | |
83 | %description static | |
84 | Static NSS Toolkit libraries. | |
85 | ||
238a25a0 | 86 | %description static -l pl.UTF-8 |
e043961c | 87 | Statyczne wersje bibliotek z NSS. |
88 | ||
909366d3 AM |
89 | %package softokn-freebl |
90 | Summary: Freebl library for the Network Security Services | |
d6727b26 | 91 | Summary(pl.UTF-8): Biblioteka freebl dla bibliotek NSS |
909366d3 AM |
92 | Group: Libraries |
93 | ||
94 | %description softokn-freebl | |
d6727b26 JB |
95 | Freebl cryptographic library for the Network Security Services. |
96 | ||
97 | %description softokn-freebl -l pl.UTF-8 | |
98 | Biblioteka kryptograficzna freebl dla bibliotek NSS. | |
909366d3 | 99 | |
e043961c | 100 | %prep |
1015f127 | 101 | %setup -q |
e043961c | 102 | %patch0 -p1 |
103 | ||
c9f1afae JB |
104 | %if 0%{!?debug:1} |
105 | # strip before signing | |
106 | sed -i -e '/export ADDON_PATH$/a\ echo STRIP \; %{__strip} --strip-unneeded -R.comment -R.note ${5}' mozilla/security/nss/cmd/shlibsign/sign.sh | |
107 | %endif | |
108 | ||
e043961c | 109 | %build |
110 | cd mozilla/security/nss | |
111 | ||
867c7e33 ER |
112 | # http://wiki.cacert.org/wiki/NSSLib |
113 | addbuiltin -n "CAcert Inc." -t "CT,C,C" < %{SOURCE3} >> lib/ckfw/builtins/certdata.txt | |
114 | ||
ab170647 | 115 | %ifarch %{x8664} ppc64 sparc64 |
f68ec3a2 PS |
116 | export USE_64=1 |
117 | %endif | |
118 | ||
8d1548f6 | 119 | %{__make} -j1 build_coreconf \ |
e043961c | 120 | NSDISTMODE=copy \ |
121 | NS_USE_GCC=1 \ | |
122 | MOZILLA_CLIENT=1 \ | |
123 | NO_MDUPDATE=1 \ | |
124 | USE_PTHREADS=1 \ | |
125 | BUILD_OPT=1 \ | |
07b248d4 | 126 | CC="%{__cc}" \ |
e043961c | 127 | OPTIMIZER="%{rpmcflags}" |
128 | ||
8d1548f6 | 129 | %{__make} -j1 build_dbm \ |
e043961c | 130 | NSDISTMODE=copy \ |
131 | NS_USE_GCC=1 \ | |
132 | MOZILLA_CLIENT=1 \ | |
133 | NO_MDUPDATE=1 \ | |
134 | USE_PTHREADS=1 \ | |
135 | BUILD_OPT=1 \ | |
07b248d4 | 136 | CC="%{__cc}" \ |
e043961c | 137 | OPTIMIZER="%{rpmcflags}" \ |
6b813326 | 138 | PLATFORM="pld" |
e3f4677f | 139 | |
8d1548f6 | 140 | %{__make} -j1 all \ |
e043961c | 141 | NSDISTMODE=copy \ |
142 | NS_USE_GCC=1 \ | |
143 | MOZILLA_CLIENT=1 \ | |
144 | NO_MDUPDATE=1 \ | |
145 | USE_PTHREADS=1 \ | |
0d478c4c JB |
146 | USE_SYSTEM_ZLIB=1 \ |
147 | ZLIB_LIBS="-lz" \ | |
07b248d4 JB |
148 | BUILD_OPT=1 \ |
149 | CC="%{__cc}" \ | |
e043961c | 150 | OPTIMIZER="%{rpmcflags}" \ |
2455c084 | 151 | PLATFORM="pld" |
e043961c | 152 | |
153 | %install | |
154 | rm -rf $RPM_BUILD_ROOT | |
909366d3 | 155 | install -d $RPM_BUILD_ROOT{%{_bindir},%{_includedir}/nss,/%{_lib},%{_libdir},%{_pkgconfigdir}} |
eec1fab1 | 156 | |
bf42a3ba | 157 | install mozilla/dist/private/nss/* $RPM_BUILD_ROOT%{_includedir}/nss |
e043961c | 158 | install mozilla/dist/public/dbm/* $RPM_BUILD_ROOT%{_includedir}/nss |
bf42a3ba | 159 | install mozilla/dist/public/nss/* $RPM_BUILD_ROOT%{_includedir}/nss |
e043961c | 160 | install mozilla/dist/pld/bin/* $RPM_BUILD_ROOT%{_bindir} |
161 | install mozilla/dist/pld/lib/* $RPM_BUILD_ROOT%{_libdir} | |
162 | ||
8d1548f6 ER |
163 | %{__sed} -e ' |
164 | s#libdir=.*#libdir=%{_libdir}#g | |
165 | s#includedir=.*#includedir=%{_includedir}#g | |
166 | s#VERSION#%{version}#g | |
167 | ' %{SOURCE1} > $RPM_BUILD_ROOT%{_pkgconfigdir}/mozilla-nss.pc | |
168 | ln -s mozilla-nss.pc $RPM_BUILD_ROOT%{_pkgconfigdir}/nss.pc | |
169 | ||
170 | NSS_VMAJOR=$(awk '/#define.*NSS_VMAJOR/ {print $3}' mozilla/security/nss/lib/nss/nss.h) | |
171 | NSS_VMINOR=$(awk '/#define.*NSS_VMINOR/ {print $3}' mozilla/security/nss/lib/nss/nss.h) | |
172 | NSS_VPATCH=$(awk '/#define.*NSS_VPATCH/ {print $3}' mozilla/security/nss/lib/nss/nss.h) | |
173 | %{__sed} -e " | |
174 | s,@libdir@,%{_libdir},g | |
175 | s,@prefix@,%{_prefix},g | |
176 | s,@exec_prefix@,%{_prefix},g | |
507f226d | 177 | s,@includedir@,%{_includedir}/nss,g |
69aeda39 ER |
178 | s,@MOD_MAJOR_VERSION@,$NSS_VMAJOR,g |
179 | s,@MOD_MINOR_VERSION@,$NSS_VMINOR,g | |
180 | s,@MOD_PATCH_VERSION@,$NSS_VPATCH,g | |
8d1548f6 ER |
181 | " %{SOURCE2} > $RPM_BUILD_ROOT%{_bindir}/nss-config |
182 | chmod +x $RPM_BUILD_ROOT%{_bindir}/nss-config | |
9e8d6618 | 183 | |
909366d3 AM |
184 | mv $RPM_BUILD_ROOT%{_libdir}/libfreebl3.so $RPM_BUILD_ROOT/%{_lib} |
185 | ln -s /%{_lib}/libfreebl3.so $RPM_BUILD_ROOT%{_libdir}/libfreebl3.so | |
69cbb7a2 AM |
186 | mv $RPM_BUILD_ROOT%{_libdir}/libfreebl3.chk $RPM_BUILD_ROOT/%{_lib} |
187 | ln -s /%{_lib}/libfreebl3.chk $RPM_BUILD_ROOT%{_libdir}/libfreebl3.chk | |
909366d3 | 188 | |
e6093db0 AM |
189 | if [ ! -f "$RPM_BUILD_ROOT%{_includedir}/nss/nsslowhash.h" ]; then |
190 | echo "ERROR: %{_includedir}/nss/nsslowhash.h not installed. Needed by glibc" >&2 | |
191 | exit 1 | |
192 | fi | |
193 | ||
eccd0672 | 194 | %clean |
195 | rm -rf $RPM_BUILD_ROOT | |
196 | ||
985ee8fc JB |
197 | %post -p /sbin/ldconfig |
198 | %postun -p /sbin/ldconfig | |
e043961c | 199 | |
200 | %files | |
201 | %defattr(644,root,root,755) | |
c9f1afae JB |
202 | %attr(755,root,root) %{_libdir}/libfreebl3.so |
203 | %attr(755,root,root) %{_libdir}/libnss3.so | |
204 | %attr(755,root,root) %{_libdir}/libnssckbi.so | |
e0debb79 JB |
205 | %attr(755,root,root) %{_libdir}/libnssdbm3.so |
206 | %attr(755,root,root) %{_libdir}/libnssutil3.so | |
c9f1afae JB |
207 | %attr(755,root,root) %{_libdir}/libsmime3.so |
208 | %attr(755,root,root) %{_libdir}/libsoftokn3.so | |
209 | %attr(755,root,root) %{_libdir}/libssl3.so | |
210 | %{_libdir}/libfreebl3.chk | |
d6727b26 | 211 | %{_libdir}/libnssdbm3.chk |
c9f1afae | 212 | %{_libdir}/libsoftokn3.chk |
e043961c | 213 | |
214 | %files devel | |
215 | %defattr(644,root,root,755) | |
ed6867e9 | 216 | %attr(755,root,root) %{_bindir}/nss-config |
c89efb4d | 217 | %{_libdir}/libcrmf.a |
d6727b26 | 218 | %{_includedir}/nss |
c9f1afae JB |
219 | %{_pkgconfigdir}/mozilla-nss.pc |
220 | %{_pkgconfigdir}/nss.pc | |
e043961c | 221 | |
222 | %files tools | |
223 | %defattr(644,root,root,755) | |
224 | %attr(755,root,root) %{_bindir}/* | |
8d1548f6 | 225 | %exclude %{_bindir}/nss-config |
e043961c | 226 | |
227 | %files static | |
228 | %defattr(644,root,root,755) | |
c9f1afae JB |
229 | %{_libdir}/libcertdb.a |
230 | %{_libdir}/libcerthi.a | |
231 | %{_libdir}/libcryptohi.a | |
232 | %{_libdir}/libdbm.a | |
233 | %{_libdir}/libfreebl3.a | |
234 | %{_libdir}/libjar.a | |
235 | %{_libdir}/libnss3.a | |
236 | %{_libdir}/libnssb.a | |
237 | %{_libdir}/libnssckfw.a | |
e0debb79 | 238 | %{_libdir}/libnssdbm3.a |
c9f1afae JB |
239 | %{_libdir}/libnssdev.a |
240 | %{_libdir}/libnsspki3.a | |
e0debb79 JB |
241 | %{_libdir}/libnssutil3.a |
242 | %{_libdir}/libpk11wrap3.a | |
c9f1afae JB |
243 | %{_libdir}/libpkcs12.a |
244 | %{_libdir}/libpkcs7.a | |
e0debb79 JB |
245 | %{_libdir}/libpkixcertsel.a |
246 | %{_libdir}/libpkixchecker.a | |
247 | %{_libdir}/libpkixcrlsel.a | |
248 | %{_libdir}/libpkixmodule.a | |
249 | %{_libdir}/libpkixparams.a | |
250 | %{_libdir}/libpkixpki.a | |
251 | %{_libdir}/libpkixresults.a | |
252 | %{_libdir}/libpkixstore.a | |
253 | %{_libdir}/libpkixsystem.a | |
254 | %{_libdir}/libpkixtop.a | |
255 | %{_libdir}/libpkixutil.a | |
c9f1afae | 256 | %{_libdir}/libsectool.a |
c9f1afae JB |
257 | %{_libdir}/libsmime3.a |
258 | %{_libdir}/libsoftokn3.a | |
259 | %{_libdir}/libssl3.a | |
909366d3 AM |
260 | |
261 | %files softokn-freebl | |
262 | %defattr(644,root,root,755) | |
263 | %attr(755,root,root) /%{_lib}/libfreebl3.so | |
69cbb7a2 | 264 | /%{_lib}/libfreebl3.chk |