Search
j0ke.net Open Build Service
>
Projects
>
mozilla
>
mozilla-nss
> mozilla-nss.spec
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File mozilla-nss.spec of Package mozilla-nss
# # spec file for package mozilla-nss (Version 3.12.0) # # Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany. # This file and all modifications and additions to the pristine # package are under the same license as the package itself. # # Please submit bugfixes or comments via http://bugs.opensuse.org/ # # norootforbuild Name: mozilla-nss BuildRequires: gcc-c++ mozilla-nspr-devel %if %suse_version == 1030 BuildRequires: sqlite-devel %endif %if %suse_version > 1030 BuildRequires: sqlite3-devel %endif License: GPL v2 or later; LGPL v2.1 or later; MOZILLA PUBLIC LICENSE (MPL/NPL) Version: 3.12.0 Release: 23 Summary: Network (Netscape) Security Services Url: http://www.mozilla.org/projects/security/pki/nss/ Group: System/Libraries Source: nss-%{version}.tar.bz2 Source1: nss.pc.in Source2: addon-certs.txt Source3: nss-config.in Patch1: nss-opt.patch Patch2: nss-sqlitename.patch Patch3: system-nspr.patch Patch4: char.patch Patch5: nss-no-rpath.patch # Remove remnant traces from the package split. Provides: libnss3 = %{version}-%{release} Obsoletes: libnss3 <= %{version}-%{release} PreReq: mozilla-nspr >= %(rpm -q --queryformat '%{VERSION}' mozilla-nspr) BuildRoot: %{_tmppath}/%{name}-%{version}-build %define nssdbdir %{_sysconfdir}/ssl/nssdb %description Network Security Services (NSS) is a set of libraries designed to support cross-platform development of security-enabled server applications. Applications built with NSS can support SSL v2 and v3, TLS, PKCS #5, PKCS #7, PKCS #11, PKCS #12, S/MIME, X.509 v3 certificates, and other security standards. Authors: -------- Mozilla Foundation <drivers@mozilla.org> %package devel License: GPL v2 or later; LGPL v2.1 or later; MOZILLA PUBLIC LICENSE (MPL/NPL) Summary: Network (Netscape) Security Services development files Group: Development/Libraries/Other Requires: mozilla-nspr-devel Requires: mozilla-nss = %{version}-%{release} %description devel Network Security Services (NSS) is a set of libraries designed to support cross-platform development of security-enabled server applications. Applications built with NSS can support SSL v2 and v3, TLS, PKCS #5, PKCS #7, PKCS #11, PKCS #12, S/MIME, X.509 v3 certificates, and other security standards. Authors: -------- Mozilla Foundation <drivers@mozilla.org> %package tools License: GPL v2 or later; LGPL v2.1 or later; MOZILLA PUBLIC LICENSE (MPL/NPL) Summary: Tools for developing, debugging, and managing applications that use NSS Group: System/Management PreReq: mozilla-nss >= %{version}-%{release} PreReq: coreutils %description tools The NSS Security Tools allow developers to test, debug, and manage applications that use NSS. Authors: -------- Mozilla Foundation <drivers@mozilla.org> %debug_package %prep %setup -n nss-%{version} -q cd mozilla %patch1 %patch2 %patch3 %patch4 %patch5 # additional CA certificates #cd security/nss/lib/ckfw/builtins #cat %{SOURCE2} >> certdata.txt #make generate %build cd mozilla/security/nss export NSPR_INCLUDE_DIR=`nspr-config --includedir` export NSPR_LIB_DIR=`nspr-config --libdir` export OPT_FLAGS="$RPM_OPT_FLAGS -g -fno-strict-aliasing" export LIBDIR=%{_libdir} %ifarch x86_64 s390x ppc64 ia64 export USE_64=1 %endif %if %suse_version > 1020 export NSS_USE_SYSTEM_SQLITE=1 %endif MAKE_FLAGS="BUILD_OPT=1 NSS_ENABLE_ECC=1" make nss_build_all $MAKE_FLAGS %install mkdir -p $RPM_BUILD_ROOT%{_libdir}/nss mkdir -p $RPM_BUILD_ROOT%{_includedir}/nss3 mkdir -p $RPM_BUILD_ROOT%{_bindir} pushd mozilla/dist/Linux* # copy headers cp -rL ../public/nss/*.h $RPM_BUILD_ROOT%{_includedir}/nss3 # copy dynamic libs cp -L lib/libnss3.so \ lib/libnssdbm3.so \ lib/libnssutil3.so \ lib/libnssckbi.so \ lib/libsmime3.so \ lib/libsoftokn3.so \ lib/libsoftokn3.chk \ lib/libssl3.so \ lib/libfreebl3.so \ lib/libfreebl3.chk \ $RPM_BUILD_ROOT%{_libdir} %if %suse_version < 1030 cp -L lib/libnsssqlite3.so \ $RPM_BUILD_ROOT%{_libdir} %endif # copy static libs cp -L lib/libcrmf.a \ lib/libnssb.a \ lib/libnssckfw.a \ $RPM_BUILD_ROOT%{_libdir} # copy tools cp -L bin/certutil \ bin/cmsutil \ bin/crlutil \ bin/modutil \ bin/pk12util \ bin/signtool \ bin/signver \ bin/ssltap \ $RPM_BUILD_ROOT%{_bindir} # copy unsupported tools cp -L bin/atob \ bin/btoa \ bin/derdump \ bin/ocspclnt \ bin/pp \ bin/selfserv \ bin/shlibsign \ bin/strsclnt \ bin/symkeyutil \ bin/tstclnt \ bin/vfyserv \ bin/vfychain \ $RPM_BUILD_ROOT%{_libdir}/nss # prepare pkgconfig file mkdir -p $RPM_BUILD_ROOT%{_libdir}/pkgconfig/ sed "s:%%LIBDIR%%:%{_libdir}:g s:%%VERSION%%:%{version}:g" \ %{SOURCE1} > $RPM_BUILD_ROOT%{_libdir}/pkgconfig/nss.pc # prepare nss-config file popd NSS_VMAJOR=`cat mozilla/security/nss/lib/nss/nss.h | grep "#define.*NSS_VMAJOR" | awk '{print $3}'` NSS_VMINOR=`cat mozilla/security/nss/lib/nss/nss.h | grep "#define.*NSS_VMINOR" | awk '{print $3}'` NSS_VPATCH=`cat mozilla/security/nss/lib/nss/nss.h | grep "#define.*NSS_VPATCH" | awk '{print $3}'` cat %{SOURCE3} | sed -e "s,@libdir@,%{_libdir},g" \ -e "s,@prefix@,%{_prefix},g" \ -e "s,@exec_prefix@,%{_prefix},g" \ -e "s,@includedir@,%{_includedir}/nss3,g" \ -e "s,@MOD_MAJOR_VERSION@,$NSS_VMAJOR,g" \ -e "s,@MOD_MINOR_VERSION@,$NSS_VMINOR,g" \ -e "s,@MOD_PATCH_VERSION@,$NSS_VPATCH,g" \ > $RPM_BUILD_ROOT/%{_bindir}/nss-config chmod 755 $RPM_BUILD_ROOT/%{_bindir}/nss-config %post -p /sbin/ldconfig %postun -p /sbin/ldconfig %post tools if [ ! -d "%{nssdbdir}" ] ; then mkdir -p "%{nssdbdir}" fi if [ ! -f "%{nssdbdir}/secmod.db" ] ; then modutil -force -dbdir "%{nssdbdir}" -create chmod 644 "%{nssdbdir}"/* fi %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-, root, root) %{_libdir}/*.so %{_libdir}/*.chk %files devel %defattr(644, root, root, 755) %{_includedir}/nss3/ %{_libdir}/*.a %{_libdir}/pkgconfig/* %attr(755,root,root) %{_bindir}/nss-config %files tools %defattr(-, root, root) %{_bindir}/* %{_libdir}/nss/ %exclude %{_bindir}/nss-config