aboutsummaryrefslogtreecommitdiff
path: root/x11-toolkits
diff options
context:
space:
mode:
authorDmitry Marakasov <amdmi3@FreeBSD.org>2021-04-26 10:19:35 +0000
committerDmitry Marakasov <amdmi3@FreeBSD.org>2021-04-26 14:19:20 +0000
commit18bc81251857f20016d280e18bbd36eb6ce0272a (patch)
tree555bfcc3f96db6cd0e8f79fde278950ad41a185c /x11-toolkits
parent0a924285557be0340804702fa74bdbf39b45dd83 (diff)
downloadports-18bc81251857f20016d280e18bbd36eb6ce0272a.tar.gz
ports-18bc81251857f20016d280e18bbd36eb6ce0272a.zip
x11-toolkits/ocaml-lablgtk2: switch to options helpers
Approved by: portmgr blanket
Diffstat (limited to 'x11-toolkits')
-rw-r--r--x11-toolkits/ocaml-lablgtk2/Makefile24
1 files changed, 7 insertions, 17 deletions
diff --git a/x11-toolkits/ocaml-lablgtk2/Makefile b/x11-toolkits/ocaml-lablgtk2/Makefile
index 8add0d7f0f02..b7c5271be2e4 100644
--- a/x11-toolkits/ocaml-lablgtk2/Makefile
+++ b/x11-toolkits/ocaml-lablgtk2/Makefile
@@ -10,6 +10,7 @@ MAINTAINER= danfe@FreeBSD.org
COMMENT= Objective Caml interface to GTK+ 2.x
LICENSE= LGPL21
+LICENSE_FILE= ${WRKSRC}/COPYING
USES= gmake gnome pkgconfig
USE_GNOME= gtk20
@@ -39,25 +40,14 @@ CONFIGURE_ENV= CAMLP4O="camlp4 pa_o.cmo pa_op.cmo pr_dump.cmo"
PATTERN= [[:space:]]*(do|then)?[[:space:]]*)cp([[:space:]]
-.include <bsd.port.options.mk>
-
-.if ${PORT_OPTIONS:MDOCS}
DOCSDIR= ${OCAML_DOCSDIR}/${PORTNAME}
PORTDOCS= COPYING README
-.endif
-
-.if ${PORT_OPTIONS:MEXAMPLES}
EXAMPLESDIR= ${OCAML_EXAMPLESDIR}/${PORTNAME}
PORTEXAMPLES= *
-.endif
-.if ${PORT_OPTIONS:MLIBRSVG2}
-CONFIGURE_ARGS+= --with-rsvg
-USE_GNOME+= librsvg2
-EXAMPLES_SUBDIRS+= rsvg
-.else
-CONFIGURE_ARGS+= --without-rsvg
-.endif
+LIBRSVG2_CONFIGURE_WITH=rsvg
+LIBRSVG2_USE= GNOME=librsvg2
+LIBRSVG2_VARS= EXAMPLES_SUBDIRS+=rsvg
post-patch:
@${REINPLACE_CMD} -E \
@@ -69,11 +59,11 @@ post-patch:
-e 's,(-ldconf )("\$$\(DESTDIR\)\$$\(OCAMLLDCONF\)"),\1ignore,' \
${WRKSRC}/src/Makefile
-post-install:
+post-install-DOCS-on:
@${MKDIR} ${STAGEDIR}${DOCSDIR}
-.if ${PORT_OPTIONS:MDOCS}
${INSTALL_DATA} ${PORTDOCS:S,^,${WRKSRC}/,} ${STAGEDIR}${DOCSDIR}
-.endif
+
+post-install-EXAMPLES-on:
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
@cd ${WRKSRC}/examples && ${COPYTREE_SHARE} \
"*.ml *.png *.rgb *.xpm text ${EXAMPLES_SUBDIRS}" \