Ticket #41532: Portfile.2

File Portfile.2, 3.1 KB (added by petrrr, 10 years ago)

updated Portfile

Line 
1# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
2# $Id$
3
4PortSystem          1.0
5
6name                igtf-ca-bundle
7version             1.56
8categories          security net
9platforms           darwin
10supported_archs     noarch
11maintainers         nikhef.nl:dennisvd bo.ingv.it:Peter.Danecek openmaintainer
12
13license             {CCBY-3 Permissive} MPL-1.1+
14
15description         The IGTF trusted certificates and metadata
16
17long_description    \
18    The International Grid Trust Federation (IGTF) maintains a list of trust \
19    anchors, root certificates and related meta-information for all the \
20    accredited authorities, i.e., those that meet or exceed the criteria \
21    mentioned in the Authentication Profiles accepted by the IGTF. \
22    For a list of those profiles, please refer to the website.
23
24homepage            http://www.igtf.net
25
26master_sites        http://dist.eugridpma.info/distribution/igtf/${version} \
27                    http://www.apgridpma.org/distribution/igtf/${version}
28
29distname            igtf-policy-installation-bundle-${version}
30
31checksums           md5     dd5447714db9b0e2609b72319826efd8 \
32                    rmd160  769ec9e69567ac47ce123d04f4a7c9e1399b8e0e \
33                    sha256  87e63b3b7a562b42c3ccf2e32e5f63bf4d3dbb3b6f9f2adf95b8903002f9cfc6
34
35livecheck.type      regex
36livecheck.url       http://dist.eugridpma.info/distribution/igtf
37livecheck.regex     ">(\\d+\\.\\d{2})/<"
38
39depends_run          port:fetch-crl
40
41# target directory for certificates
42set certdir ${prefix}/etc/grid-security/certificates
43
44configure.args-append \
45        --prefix=${destroot}${certdir} \
46        --with-profile=classic \
47        --with-profile=slcs \
48        --with-profile=mics
49
50build {}
51
52post-destroot {
53    ln -s ${certdir} ${destroot}${prefix}/share/certificates
54
55    set dest_doc ${destroot}${prefix}/share/doc
56    xinstall -d ${dest_doc}
57    xinstall -m 644 -W ${worksrcpath} \
58        CHANGES \
59        LICENSE \
60        README.txt \
61            ${dest_doc}
62    # These are added to comply with MPL licensing
63    xinstall -m 644 -${portpath}/files \
64        LICENSE-CC-BY-3_0 \
65        LICENSE-MPL-1_1 \
66            ${dest_doc}
67}
68
69post-activate {
70    ui_msg "###########################################################"
71    ui_msg "# Fetching CRLs ...                                        "
72    ui_msg "###########################################################"
73   
74    system "${prefix}/sbin/fetch-crl -v"
75}
76post-deactivate {
77    ui_msg "###########################################################"
78    ui_msg "# Purging CRLs ...                                        "
79    ui_msg "###########################################################"
80
81    system "${prefix}/sbin/clean-crl -v -l ${certdir}"
82
83    # purge fetch-crl cache
84    eval { file delete [ glob ${prefix}/var/cache/fetch-crl/*.state ] }
85    #foreach {filename} [ glob ${prefix}/var/cache/fetch-crl/*.state ] {
86    #    delete $filename
87    #}
88
89    # cleanup leftover directories
90    catch {file delete ${certdir}}
91    catch {file delete ${prefix}/etc/grid-security}
92}