Contents of /smage/branches/alx07x-stable/core/ca-certificates/ca-certificates-20200601-r1.smage2
Parent Directory | Revision Log
Revision 14938 -
(show annotations)
(download)
Thu Aug 6 12:52:20 2020 UTC (4 years, 1 month ago) by niro
File size: 1910 byte(s)
Thu Aug 6 12:52:20 2020 UTC (4 years, 1 month ago) by niro
File size: 1910 byte(s)
-release branches/alx07x-stable
1 | # $Id$ |
2 | |
3 | PNAME="ca-certificates" |
4 | PVER="20200601" |
5 | PBUILD="r1" |
6 | |
7 | PCAT="app-crypt" |
8 | |
9 | DESCRIPTION="Common CA certificates." |
10 | HOMEPAGE="http://packages.qa.debian.org/c/ca-certificates.html" |
11 | |
12 | DEPEND=">= dev-libs/openssl-1 |
13 | >= app-shells/bash-4.2 |
14 | >= sys-apps/coreutils-8 |
15 | >= virtual/debianutils |
16 | >= sys-apps/findutils-4.4 |
17 | >= virtual/sed" |
18 | |
19 | SDEPEND=">= dev-lang/python-2.7" |
20 | |
21 | SRCFILE="${PNAME}_${PVER}.tar.xz" |
22 | #SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" |
23 | SRCDIR="${BUILDDIR}/work" |
24 | |
25 | # do not strip libtool files and check not supported |
26 | msetfeature "libtool" "!check" |
27 | |
28 | sminclude mbuild mtools |
29 | |
30 | SRC_URI=( |
31 | http://ftp.debian.org/debian/pool/main/c/${PNAME}/${SRCFILE} |
32 | mirror://${PNAME}/${SRCFILE} |
33 | ) |
34 | |
35 | UP2SUBSTITUTE="certificates_" |
36 | UP2EXCLUDE="~" |
37 | UP2DATE="updatecmd 'http://ftp.debian.org/debian/pool/main/c/${PNAME}' | highesttarball xz" |
38 | |
39 | src_compile() |
40 | { |
41 | cd ${SRCDIR} |
42 | mmake || die |
43 | } |
44 | |
45 | src_install() |
46 | { |
47 | cd ${SRCDIR} |
48 | |
49 | # create cert directory structure |
50 | mkeepdir /etc/ca-certificates/update.d || die |
51 | mkeepdir /etc/ssl/certs || die |
52 | minstalldir /usr/sbin || die |
53 | minstalldir /usr/share/ca-certificates || die |
54 | |
55 | mmake DESTDIR=${BINDIR} install || die |
56 | |
57 | # create certs config |
58 | MCONFIG="/etc/ca-certificates.conf" |
59 | mclearconfig |
60 | maddconfig "# Automatically generated by ${PKGNAME}-${PVER}-${PBUILD}" |
61 | maddconfig '# Do not modifiy, see update-ca-certificates man page' |
62 | maddconfig '#' |
63 | cd ${BINDIR}/usr/share/ca-certificates |
64 | find . -name '*.crt' | sort | cut -b3- >> ${BINDIR}/${MCONFIG} || die |
65 | |
66 | # mask certs config from etc protect |
67 | minstalldir /etc/env.d || die |
68 | MCONFIG="/etc/env.d/40ca-certificates" |
69 | mclearconfig || die |
70 | maddconfig 'CONFIG_PROTECT_MASK="/etc/ca-certificates.conf"' || die |
71 | } |
72 | |
73 | postinstall() |
74 | { |
75 | if [[ ${MROOT} = / ]] || [[ -z ${MROOT} ]] |
76 | then |
77 | update-ca-certificates --fresh |
78 | fi |
79 | } |
80 | |
81 | postremove() |
82 | { |
83 | if [ ! -x ${MROOT}/usr/sbin/update-ca-certificates ] |
84 | then |
85 | rm -f ${MROOT}/etc/ssl/certs/ca-certificates.crt |
86 | fi |
87 | } |