Ticket #46946: Portfile

File Portfile, 3.2 KB (added by teh-maxh (Max Harmony), 10 years ago)
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: Portfile 132871 2015-02-11 23:48:35Z jann@macports.org $
3
4PortSystem          1.0
5
6# When updating gnupg2, update gpg-agent also if applicable.
7name                gnupg2
8version             2.0.27
9revision            1
10categories          mail security
11maintainers         ionic openmaintainer
12license             GPL-3+
13installs_libs       no
14
15description         GNU pretty-good-privacy package
16long_description    GnuPG is a complete and free replacement for PGP. Because       \
17                    it does not use the patented IDEA algorithm, it can be used     \
18                    without any restrictions. GnuPG is a RFC2440 (OpenPGP)          \
19                    compliant application.
20homepage            http://www.gnupg.org
21platforms           darwin freebsd sunos
22use_bzip2           yes
23distname            gnupg-${version}
24master_sites        gnupg:gnupg
25conflicts           gnupg21
26
27use_bzip2           yes
28
29checksums           rmd160  52aaf841339713aef9e2e034b1e045bec31d6322 \
30                    sha256  57646d3e4b919fa1e5c8f1c0cf5fe1215333041c493a5ebc4b8f2978dbe930f2
31
32# gpg-agent is built separately from the rest of gnupg2 to enable gnupg 1.x
33# users to use gpg-agent as well.
34# gnupg2, however, requires gpg-agent to run, and so gnupg2 depends on gpg-agent.
35configure.args      --disable-agent \
36                    --without-adns
37
38# glib fails to find the right stdint.h  It picks clang's internal one rather
39# than the system header
40configure.env       gl_cv_absolute_stdint_h=/usr/include/stdint.h
41
42depends_lib         port:libiconv           \
43                    port:gettext            \
44                    port:zlib               \
45                    port:bzip2              \
46                    port:bison              \
47                    port:gpg-agent          \
48                    port:libassuan          \
49                    port:libksba            \
50                    port:libgcrypt          \
51                    port:libgpg-error       \
52                    port:openldap           \
53                    port:pth                \
54                    port:readline           \
55                    port:curl               \
56                    port:libusb-compat
57
58patchfiles          patch-common-homedir.c.diff \
59                    patch-configure.diff \
60                    patch-tests__openpgp__Makefile.in.diff
61
62platform darwin {
63    patchfiles-append   patch-gpg_agent-launchd.diff
64}
65
66post-patch {
67    reinplace "s|@PREFIX@|${prefix}|g" ${worksrcpath}/common/homedir.c
68}
69
70post-destroot {
71    delete ${destroot}${prefix}/share/man/man1/gpg-zip.1
72}
73
74test.run            yes
75test.dir            ${worksrcpath}/tests
76test.target         check
77
78# See also the post-patch above.
79# Apparently we have no way of forcing gnupg2 to build without DirMngr support,
80# so we have to just hope we don't run into any problems.
81variant dirmngr description {Enable the use of DirMngr by gpgsm} {
82    depends_lib-append  port:dirmngr
83}
84
85livecheck.type      regex
86livecheck.url       ftp://ftp.gnupg.org/gcrypt/gnupg/
87livecheck.regex     gnupg-(2\\.0\\.\\d+)