blob: f86676e0182a07bcc2f4d8a71caa80c65738bf58 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
|
# Created by: Stephane Legrand <stephane@FreeBSD.org>
# $FreeBSD$
PORTNAME= net
PORTVERSION= 3.7.3
CATEGORIES= www
MASTER_SITES= http://download.camlcity.org/download/
PKGNAMEPREFIX= ocaml-
DISTNAME= ocaml${PORTNAME}-${PORTVERSION}
MAINTAINER= jaapb@kerguelen.org
COMMENT= OCaml modules for Internet applications
LICENSE= GPLv2
BUILD_DEPENDS= ${SA_DIR}/pcre/pcre.a:${PORTSDIR}/devel/ocaml-pcre
RUN_DEPENDS= ${SA_DIR}/pcre/pcre.a:${PORTSDIR}/devel/ocaml-pcre
CONFLICTS= ocaml-equeue-2* ocaml-netclient-0*
USES= gmake
USE_OCAML= yes
USE_OCAML_FINDLIB= yes
USE_OCAML_LDCONFIG= yes
USE_OCAMLFIND_PLIST= yes
HAS_CONFIGURE= yes
ALL_TARGET= all opt
MAKE_JOBS_UNSAFE= yes
PLIST_FILES= bin/netplex-admin \
bin/ocamlrpcgen
DOCSDIR= ${PREFIX}/share/doc/ocaml/${PKGNAMEPREFIX}${PORTNAME}
EXAMPLESDIR= ${PREFIX}/share/examples/ocaml/${PKGNAMEPREFIX}${PORTNAME}
SA_DIR= ${LOCALBASE}/${OCAML_SITELIBDIR}
PORTDOCS= *
PORTEXAMPLES= *
OCAML_PKGDIRS= netsys netshm equeue shell netstring rpc-generator \
rpc pop smtp netclient netcgi2 netgssapi netplex \
netcgi2-plex netcamlbox netmulticore rpc-auth-local \
netstring-pcre
OCAML_LDLIBS= ${OCAML_PKGDIRS:S/^/${OCAML_SITELIBDIR}\//}
OPTIONS_DEFINE= SSL NETHTTPD AUTH_DH GTK2 APACHE ZIP SCRAM EXAMPLES DOCS
OPTIONS_DEFAULT=SSL
AUTH_DH_DESC= Diffie-Hellman authorization support
NETHTTPD_DESC= Integrated HTTP daemon
SCRAM_DESC= SCRAM support
ZIP_DESC= Compression support
APACHE_DESC= Apache mod connector (experimental)
CONFIGURE_ARGS+=-disable-gtk \
-enable-pcre
SSL_BUILD_DEPENDS= ${SA_DIR}/ssl/ssl.a:${PORTSDIR}/security/ocaml-ssl
SSL_RUN_DEPENDS= ${SA_DIR}/ssl/ssl.a:${PORTSDIR}/security/ocaml-ssl
AUTH_DH_BUILD_DEPENDS= ${SA_DIR}/cryptgps/cryptgps.a:${PORTSDIR}/security/ocaml-cryptgps
AUTH_DH_RUN_DEPENDS= ${SA_DIR}/cryptgps/cryptgps.a:${PORTSDIR}/security/ocaml-cryptgps
GTK2_BUILD_DEPENDS= lablgtk2:${PORTSDIR}/x11-toolkits/ocaml-lablgtk2
GTK2_RUN_DEPENDS= lablgtk2:${PORTSDIR}/x11-toolkits/ocaml-lablgtk2
ZIP_BUILD_DEPENDS= ${SA_DIR}/zip/zip.a:${PORTSDIR}/archivers/ocaml-zip
ZIP_RUN_DEPENDS= ${SA_DIR}/zip/zip.a:${PORTSDIR}/archivers/ocaml-zip
SCRAM_BUILD_DEPENDS= ${SA_DIR}/cryptokit/cryptokit.a:${PORTSDIR}/security/ocaml-cryptokit
SCRAM_RUN_DEPENDS= ${SA_DIR}/cryptokit/cryptokit.a:${PORTSDIR}/security/ocaml-cryptokit
.include <bsd.port.options.mk>
.if ${PORT_OPTIONS:MSSL}
CONFIGURE_ARGS+= -enable-ssl
OCAML_PKGDIRS+= equeue-ssl rpc-ssl
.endif
.if ${PORT_OPTIONS:MNETHTTPD}
CONFIGURE_ARGS+= -with-nethttpd
OCAML_PKGDIRS+= nethttpd nethttpd-for-netcgi2
.endif
.if ${PORT_OPTIONS:MAUTH_DH}
CONFIGURE_ARGS+= -with-rpc-auth-dh
OCAML_PKGDIRS+= rpc-auth-dh
.endif
.if ${PORT_OPTIONS:MGTK2}
CONFIGURE_ARGS+= -enable-gtk2
OCAML_PKGDIRS+= equeue-gtk2
.endif
.if ${PORT_OPTIONS:MAPACHE}
USE_APACHE= 22+
CONFIGURE_ARGS+= -enable-apache -apxs ${APXS} -apache ${HTTPD}
OCAML_PKGDIRS+= netcgi_apache
.endif
.if ${PORT_OPTIONS:MZIP}
CONFIGURE_ARGS+= -enable-zip
OCAML_PKGDIRS+= netzip
.endif
.if ${PORT_OPTIONS:MSCRAM}
CONFIGURE_ARGS+= -enable-crypto
OCAML_PKGDIRS+= netmech-scram
.endif
post-patch:
${REINPLACE_CMD} -e '/\.libs/d' \
${WRKSRC}/src/netcgi2-apache/Makefile.def
${REINPLACE_CMD} -e 's/camlzip/zip/' \
${WRKSRC}/configure \
${WRKSRC}/src/netzip/META.in \
${WRKSRC}/src/netzip/Makefile
post-install:
.if ${PORT_OPTIONS:MDOCS}
@${MKDIR} ${STAGEDIR}${DOCSDIR}/
@(cd ${WRKSRC}/doc/ && ${COPYTREE_SHARE} \* ${STAGEDIR}${DOCSDIR}/)
.endif
.if ${PORT_OPTIONS:MEXAMPLES}
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}/
@(cd ${WRKSRC}/examples/ && \
${COPYTREE_SHARE} \* ${STAGEDIR}${EXAMPLESDIR}/)
.endif
.include <bsd.port.mk>
|