wok-next view cacerts/receipt @ rev 19549
Up cacerts (20161124), perl no more need in post_install
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Fri Dec 09 03:40:48 2016 +0200 (2016-12-09) |
parents | cfa2c2f63692 |
children | f1752c8b2a2a |
line source
1 # SliTaz package receipt.
3 PACKAGE="cacerts"
4 VERSION="20161124"
5 CATEGORY="security"
6 SHORT_DESC="Certificate Authority Certificates"
7 MAINTAINER="al.bobylev@gmail.com"
8 LICENSE="MPL2"
9 WEB_SITE="http://www.linuxfromscratch.org/blfs/view/svn/postlfs/cacerts.html"
10 TARBALL="$PACKAGE-$VERSION.txt"
11 #WGET_URL="https://hg.mozilla.org/releases/mozilla-release/file/default/security/nss/lib/ckfw/builtins/certdata.txt"
12 WGET_URL="http://anduin.linuxfromscratch.org/BLFS/other/certdata.txt"
13 HOST_ARCH="any"
15 DEPENDS="openssl"
16 BUILD_DEPENDS="perl openssl locale-en"
18 # Rules to configure and make the package.
19 compile_rules()
20 {
21 mv -f *.txt certdata.txt
22 cp -a $stuff/* $src
23 ./make-ca.sh &&
24 ./remove-expired-certs.sh $src/certs
25 }
27 # Rules to gen a SliTaz package suitable for Tazpkg.
28 genpkg_rules()
29 {
30 mkdir -p $fs/etc/ssl/certs
31 cp -a $src/certs/*.pem $fs/etc/ssl/certs
32 cp -a $src/ca-bundle.crt $fs/etc/ssl
33 ln -s ../ca-bundle.crt $fs/etc/ssl/certs/ca-certificates.crt
34 }
36 post_install()
37 {
38 # Rehash certificates.
39 # Use simplified plain shell equivalent to the Perl `c_rehash`
40 # (see openssl package). Normal no output here.
41 cd "$1/etc/ssl/certs"
42 find . -type l -delete
43 for i in $(ls *.pem); do
44 j="$(openssl x509 -hash -noout -in $i)"
45 [ -n "$j" ] && ln -s $i $j.0
46 done
47 }
49 post_remove()
50 {
51 # Remove broken symlinks
52 find "$1/etc/ssl/certs" -type l ! -exec test -e \{\} \; -delete
53 }