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