Ticket #34143: Portfile

File Portfile, 3.2 KB (added by pierreetienne.meunier@…, 12 years ago)

/Users/pe/Projets/macports-trunk/dports/devel/ocaml-ocamlnet/Portfile

Line 
1# $Id: Portfile 92002 2012-04-15 21:41:01Z landonf@macports.org $
2
3PortSystem          1.0
4
5name                ocaml-ocamlnet
6version             3.4
7revision            1
8categories          devel ml
9maintainers         landonf openmaintainer
10license             {BSD GPL-2 LGPL-2}
11description         Internet protocols and helper data structures for OCaml.
12long_description    Internet protocols (http, cgi, email etc.) and helper \
13                    data structures (mail messages, character sets, etc.) \
14                    Ocamlnet implements a number of Internet protocols (http \
15                    client & server, cgi and cgi variants, SunRPC, FTP, POP, \
16                    SMTP) and is a strong base for web and Internet \
17                    programming.
18
19homepage            http://projects.camlcity.org/projects/ocamlnet.html
20platforms           darwin
21master_sites        http://download.camlcity.org/download/
22
23distname            ocamlnet-${version}
24
25checksums           md5     920414f896af983e7458c03a492f7c62 \
26                    sha1    2eed08e68175089f6bba4732aa99fc07843c7c92 \
27                    rmd160  90baea35fc4ea37db6a3a611408fc676afc216f4
28
29
30depends_lib         port:ocaml \
31                    port:ocaml-findlib \
32                    port:ocaml-pcre
33
34# ocaml is not universal
35universal_variant   no
36
37post-patch {
38    set ocaml_site_path [exec ocamlfind printconf destdir]
39    reinplace       "s|\$(OCAMLFIND) install|\$(OCAMLFIND) install -destdir ${destroot}/${ocaml_site_path}|g" \
40                    ${worksrcpath}/Makefile
41}
42
43configure.pre_args
44
45build.target        all opt
46use_parallel_build  no
47
48pre-destroot {
49    set ocaml_site_path [exec ocamlfind printconf destdir]
50    file mkdir ${destroot}${ocaml_site_path}/stublibs
51    destroot.args DESTDIR="${destroot}" OCAMLFIND_DESTDIR="${destroot}${ocaml_site_path}"
52}
53
54livecheck.type      regex
55livecheck.regex     {ocamlnet-(\d+(?:\.\d+)*)\.tar}
56
57variant no_pcre description Disable parts that depend on lablgtk {
58        configure.args-append -disable-pcre
59        depends_lib-delete port:ocaml-pcre
60}
61
62variant gtk description Enable parts that depend on lablgtk {
63        configure.args-append -enable-gtk
64        depends_lib-append port:lablgtk
65}
66variant gtk2 description Enable parts that depend on lablgtk2 {
67        configure.args-append -enable-gtk2
68        depends_lib-append port:lablgtk2
69}
70variant tcl description Enable parts that depend on tcltk {
71        configure.args-append -enable-tcl
72}
73variant ssl description Enable parts that depend on SSL {
74        configure.args-append -enable-ssl
75        depends_lib-append port:openssl
76}
77variant zip description Enable parts that depend on camlzip {
78        configure.args-append -enable-zip
79        depends_lib-append port:ocaml-zip
80}
81variant crypto description Enable parts that depend on cryptokit {
82        configure.args-append -enable-crypto
83        depends_lib-append port:cryptokit
84}
85variant apache description Enable Apache mod connector (EXPERIMENTAL) {
86        configure.args-append -enable-apache
87}
88variant nethttpd description Enable nethttpd web server component (GPL!) {
89        configure.args-append   -with-nethttpd
90}
91variant rpc_auth_dh description Enable support for SecureRPC (Diffie-Hellman auth) {
92        configure.args-append   -with-rpc-auth-dh
93}