wok-next view nss/receipt @ rev 6509
Up: cromfs to 1.5.9.
author | Christopher Rogers <slaxemulator@gmail.com> |
---|---|
date | Fri Oct 01 20:48:34 2010 +0000 (2010-10-01) |
parents | f581472fff1b |
children | f620c0d3e9f4 |
line source
1 # SliTaz package receipt.
3 PACKAGE="nss"
4 VERSION="3.12.7"
5 CATEGORY="utilities"
6 SHORT_DESC="Mozilla Network Security Services (NSS)."
7 MAINTAINER="rocky@slitaz.org"
8 DEPENDS="libfirefox sqlite zlib"
9 BUILD_DEPENDS="firefox-dev sqlite-dev zlib-dev perl"
10 TARBALL="$PACKAGE-$VERSION.tar.gz"
11 WEB_SITE="http://www.mozilla.org/projects/security/pki/nss/"
12 WGET_URL="ftp://ftp.mozilla.org/pub/security/nss/releases/NSS_${VERSION//./_}_RTM/src/${TARBALL}"
14 # Rules to configure and make the package.
15 compile_rules()
16 {
17 cd $src
18 # Adds the SPI Inc. and CAcert.org CA certificates - patch from Debian
19 patch -Np1 -i ../stuff/add_spi+cacert_ca_certs.patch
20 # Adds transitional SSL renegotiate support - patch from Debian
21 patch -Np1 -i ../stuff/ssl-renegotiate-transitional.patch
22 # Builds against system sqlite - patch from Fedora
23 patch -Np0 -i ../stuff/nss-nolocalsql.patch
24 # Removes rpath
25 patch -Np0 -i ../stuff/nss-no-rpath.patch
27 export NSPR_INCLUDE_DIR=$(ls -d /usr/include/firefox-*)
28 export NSPR_LIB_DIR=$(ls -d /usr/lib/firefox-*/lib)
29 export NSS_USE_SYSTEM_SQLITE=1
30 export BUILD_OPT=1
32 make -j1 -C mozilla/security/nss build_coreconf build_dbm all
34 mkdir -p $PWD/_pkg/usr/bin
35 mkdir -p $PWD/_pkg/usr/lib/pkgconfig
36 mkdir -p $PWD/_pkg/usr/include/nss
38 NSS_VMAJOR=`grep "#define.*NSS_VMAJOR" mozilla/security/nss/lib/nss/nss.h | awk '{print $3}'`
39 NSS_VMINOR=`grep "#define.*NSS_VMINOR" mozilla/security/nss/lib/nss/nss.h | awk '{print $3}'`
40 NSS_VPATCH=`grep "#define.*NSS_VPATCH" mozilla/security/nss/lib/nss/nss.h | awk '{print $3}'`
42 sed ../stuff/nss.pc.in -e "s,%libdir%,/usr/lib,g" \
43 -e "s,%prefix%,/usr,g" \
44 -e "s,%exec_prefix%,/usr/bin,g" \
45 -e "s,%includedir%,/usr/include/nss,g" \
46 -e "s,%NSPR_VERSION%,${VERSION},g" \
47 -e "s,%NSS_VERSION%,${VERSION},g" \
48 > $PWD/_pkg/usr/lib/pkgconfig/nss.pc || return 1
50 sed ../stuff/nss-config.in -e "s,@libdir@,/usr/lib,g" \
51 -e "s,@prefix@,/usr/bin,g" \
52 -e "s,@exec_prefix@,/usr/bin,g" \
53 -e "s,@includedir@,/usr/include/nss,g" \
54 -e "s,@MOD_MAJOR_VERSION@,${NSS_VMAJOR},g" \
55 -e "s,@MOD_MINOR_VERSION@,${NSS_VMINOR},g" \
56 -e "s,@MOD_PATCH_VERSION@,${NSS_VPATCH},g" \
57 > $PWD/_pkg/usr/bin/nss-config || return 1
58 chmod 755 $PWD/_pkg/usr/bin/nss-config || return 1
60 for file in libsoftokn3.so libfreebl3.so libnss3.so libnssutil3.so \
61 libssl3.so libsmime3.so libnssckbi.so libnssdbm3.so
62 do
63 cp mozilla/dist/*.OBJ/lib/${file} $PWD/_pkg/usr/lib/ || return 1
64 done
65 for file in libcrmf.a libnssb.a libnssckfw.a; do
66 cp mozilla/dist/*.OBJ/lib/${file} $PWD/_pkg/usr/lib/ || return 1
67 done
69 for file in certutil cmsutil crlutil modutil pk12util signtool signver ssltap; do
70 cp mozilla/dist/*.OBJ/bin/${file} $PWD/_pkg/usr/bin/ || return 1
71 done
73 cp mozilla/dist/public/nss/*.h $PWD/_pkg/usr/include/nss || return 1
74 }
76 # Rules to gen a SliTaz package suitable for Tazpkg.
77 genpkg_rules()
78 {
79 mkdir -p $fs/usr
80 cp -a $_pkg/usr/bin $fs/usr
81 rm $fs/usr/bin/nss-config
82 }