1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
|
# $Id: PKGBUILD 55628 2011-09-16 13:40:10Z bluewind $
# Maintainer : Ionut Biru <ibiru@archlinux.org>
_pkgbasename=nss
pkgname=lib32-$_pkgbasename
pkgver=3.12.11
pkgrel=1
pkgdesc="Mozilla Network Security Services (32-bit)"
arch=('x86_64')
url="http://www.mozilla.org/projects/security/pki/nss/"
license=('MPL' 'GPL')
_nsprver=4.8.9
depends=("lib32-nspr>=${_nsprver}" 'lib32-sqlite3>=3.6.17' "$_pkgbasename" 'lib32-zlib')
makedepends=('gcc-multilib' 'perl')
options=('!strip')
source=(ftp://ftp.mozilla.org/pub/security/nss/releases/NSS_${pkgver//./_}_RTM/src/${_pkgbasename}-${pkgver}.tar.gz
nss-no-rpath.patch
nss.pc.in
distrust-diginotar.patch
add_spi+cacert_ca_certs.patch
ssl-renegotiate-transitional.patch)
md5sums=('ca0ca058380be200cf247ea2496b5352'
'e5c97db0c884d5f4cfda21e562dc9bba'
'c547b030c57fe1ed8b77c73bf52b3ded'
'bbd7d8a8e2f6ffc8b3e5f6614e5f3ccf'
'ba2357c5b9881bfd7d54b037954ba0ff'
'd83c7b61abb7e9f8f7bcd157183d1ade')
build() {
cd "${srcdir}/${_pkgbasename}-${pkgver}/mozilla"
# Distrust DigiNotar root CA - backported from CVS (https://bugzilla.mozilla.org/show_bug.cgi?id=682927)
patch -Np0 -i "${srcdir}/distrust-diginotar.patch"
# Adds the SPI Inc. and CAcert.org CA certificates - patch from Debian
patch -Np2 -i "${srcdir}/add_spi+cacert_ca_certs.patch"
# Adds transitional SSL renegotiate support - patch from Debian
patch -Np2 -i "${srcdir}/ssl-renegotiate-transitional.patch"
# Removes rpath
patch -Np2 -i "${srcdir}/nss-no-rpath.patch"
# Respect LDFLAGS
sed -e 's/\$(MKSHLIB) -o/\$(MKSHLIB) \$(LDFLAGS) -o/g' \
-i security/coreconf/rules.mk
cd "${srcdir}/${_pkgbasename}-${pkgver}"
export PKG_CONFIG_PATH=/usr/lib32/pkgconfig
export BUILD_OPT=1
export PKG_CONFIG_ALLOW_SYSTEM_LIBS=1
export PKG_CONFIG_ALLOW_SYSTEM_CFLAGS=1
export NSS_USE_SYSTEM_SQLITE=1
export NSPR_INCLUDE_DIR=`pkg-config --cflags-only-I nspr | sed 's/-I//'`
export NSPR_LIB_DIR=`pkg-config --libs-only-L nspr | sed 's/-L.//'`
export XCFLAGS="${CFLAGS}"
make -j 1 -C mozilla/security/coreconf
make -j 1 -C mozilla/security/dbm
make -j 1 -C mozilla/security/nss
}
package() {
cd "${srcdir}/${_pkgbasename}-${pkgver}"
install -m755 -d "${pkgdir}/usr/lib32/pkgconfig"
sed "${srcdir}/nss.pc.in" -e "s,%libdir%,/usr/lib32,g" \
-e "s,%prefix%,/usr,g" \
-e "s,%exec_prefix%,/usr/bin,g" \
-e "s,%includedir%,/usr/include/nss,g" \
-e "s,%NSPR_VERSION%,${pkgver},g" \
-e "s,%NSS_VERSION%,${pkgver},g" > \
"${pkgdir}/usr/lib32/pkgconfig/nss.pc"
ln -sf nss.pc "${pkgdir}/usr/lib32/pkgconfig/mozilla-nss.pc"
chmod 644 ${pkgdir}/usr/lib32/pkgconfig/*.pc
for file in libsoftokn3.so libfreebl3.so libnss3.so libnssutil3.so \
libssl3.so libsmime3.so libnssckbi.so libnssdbm3.so
do
install -m755 mozilla/dist/*.OBJ/lib/${file} "${pkgdir}/usr/lib32/"
done
install -m644 mozilla/dist/*.OBJ/lib/libcrmf.a "${pkgdir}/usr/lib32/"
install -m644 mozilla/dist/*.OBJ/lib/*.chk "${pkgdir}/usr/lib32/"
}
|