Ticket #48809: Portfile

File Portfile, 1.9 KB (added by greeneg (Gary Greene), 9 years ago)

Portfile patched with the extra flags for clang

Line 
1# $Id: Portfile 111161 2013-09-16 03:01:08Z jmr@macports.org $
2
3PortSystem      1.0
4
5name            lsh
6version         1.5.4
7revision        1
8description     A GNU implementation of the Secure Shell protocols
9long_description        \
10        lsh is a free implementation (in the GNU sense) of the ssh \
11version 2 protocol, currently being standardised by the IETF SECSH \
12working group
13
14categories      net
15license         GPL-2+
16maintainers     nomaintainer
17platforms       darwin
18homepage        http://www.lysator.liu.se/~nisse/lsh/
19
20master_sites    http://www.lysator.liu.se/~nisse/archive/ \
21                ftp://ftp.lysator.liu.se/pub/security/lsh/
22checksums       md5 5cb5bccf17e7819a6db3e447854a310c
23patchfiles      \
24        patch-src-argp-Makefile.in.diff  patch-src-argp-argp-pvh.c.diff \
25        patch-src-argp-argp-ba.c.diff    patch-src-nettle-configure.diff \
26        patch-src-argp-argp-pv.c.diff    patch-src-spki-configure.diff \
27        patch-src-lsh_pam_checkpw.c.diff
28
29depends_lib     lib:liboop:liboop               lib:libgmp:gmp \
30                lib:libreadline:readline
31
32set defaultcflags               "-I${prefix}/include"
33set defaultconfigureargs        "--disable-datafellows-workarounds --with-include-path=${prefix}/include --with-lib-path=${prefix}/lib --with-tcpwrappers --with-pam --disable-kerberos"
34
35
36platform darwin {
37    post-extract {
38        system "mkdir -p ${workpath}/paminclude"
39        system "ln -sf /usr/include/pam ${workpath}/paminclude/security"
40    }
41
42        patchfiles-append       patch-src-unix_user.c.diff
43
44        post-patch {
45                # fix time stamps
46                system "touch \"${worksrcpath}/src/unix_user.c.x\""
47        }
48
49    set platformcflags  "-I${workpath}/paminclude"
50        configure.args ${defaultconfigureargs} CPPFLAGS="${defaultcflags} ${platformcflags}" LDFLAGS="-L${prefix}/lib"
51
52    post-install {
53        ui_msg "Additionally, for PAM, you need to copy /etc/pam.d/sshd to "
54        ui_msg "/etc/pam.d/lshd, or use another config with pam_securityserver.so."
55    }
56}
57
58configure.cflags-append "-std=gnu89"
59configure.args ${defaultconfigureargs} CPPFLAGS="${defaultcflags}" LDFLAGS="-L${prefix}/lib"