aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lang/ocaml/Makefile34
1 files changed, 18 insertions, 16 deletions
diff --git a/lang/ocaml/Makefile b/lang/ocaml/Makefile
index d04a7455662e..9dcdad169e05 100644
--- a/lang/ocaml/Makefile
+++ b/lang/ocaml/Makefile
@@ -35,19 +35,8 @@ MODOPT= camlp4o camlp4r ocamlc ocamldep ocamldoc ocamllex ocamlopt
PATTERN= [[:space:]]*(do|then)?[[:space:]]*)(\$$\(CP\)|cp)([[:space:]]
NO_STAGE= yes
-.include <bsd.port.pre.mk>
-.if ${ARCH} == powerpc
-ARCH= power
-.endif
-
-.if ${ARCH} == power
-PLIST_SUB+= PROF="@comment "
-.else
-PLIST_SUB+= PROF=""
-.endif
-
-.include "${FILESDIR}/manfiles"
+.include <bsd.port.options.mk>
.if ${PORT_OPTIONS:MTHREADS}
PLIST_SUB+= THREADS=""
@@ -80,15 +69,28 @@ CONFLICTS+= ocaml-[0-9]* ocaml-nox11-[0-9]*
.endif
CONFIGURE_ARGS+=-no-tk
.else
-USE_TK= 84+
-INVALID_TK_VER = 86
+USES+= tk:84,85
.include "${PORTSDIR}/Mk/bsd.tcl.mk"
PLIST_SUB+= TK=""
CONFLICTS+= ocaml-nox11-[0-9]* ocaml-notk-[0-9]*
CONFIGURE_ARGS+= -tkdefs \
"-I${TCL_INCLUDEDIR} -I${TK_INCLUDEDIR} ${THR_CPP}" \
- -tklibs "-L${LOCALBASE}/lib -ltk${TK_VER:S|.||} \
- -ltcl${TCL_VER:S|.||} ${THR_LD}"
+ -tklibs "-L${LOCALBASE}/lib -ltk${TK_SHLIB_VER} \
+ -ltcl${TCL_SHLIB_VER} ${THR_LD}"
+.endif
+
+.include <bsd.port.pre.mk>
+
+.include "${FILESDIR}/manfiles"
+
+.if ${ARCH} == powerpc
+ARCH= power
+.endif
+
+.if ${ARCH} == power
+PLIST_SUB+= PROF="@comment "
+.else
+PLIST_SUB+= PROF=""
.endif
.if ${ARCH} == sparc64