aboutsummaryrefslogtreecommitdiff
path: root/x11/xpra-html5/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'x11/xpra-html5/Makefile')
-rw-r--r--x11/xpra-html5/Makefile28
1 files changed, 20 insertions, 8 deletions
diff --git a/x11/xpra-html5/Makefile b/x11/xpra-html5/Makefile
index 32d5244a0093..54823b09dc59 100644
--- a/x11/xpra-html5/Makefile
+++ b/x11/xpra-html5/Makefile
@@ -1,6 +1,5 @@
PORTNAME= xpra-html5
-PORTVERSION= 5.0
-PORTREVISION= 1
+PORTVERSION= 6.1
DISTVERSIONPREFIX= v
CATEGORIES= x11
@@ -15,13 +14,20 @@ BUILD_DEPENDS= brotli:archivers/brotli
USES= python:3.6+,build
-OPTIONS_DEFINE= MINIFY
-OPTIONS_DEFAULT= MINIFY
+OPTIONS_DEFAULT= YUICOMPRESSOR
-MINIFY_DESC= Minify JavaScript source files
-MINIFY_BUILD_DEPENDS= yuicompressor:www/yuicompressor
-MINIFY_VARS= minifier=yuicompressor
-MINIFY_VARS_OFF= minifier=copy
+OPTIONS_RADIO= MINIFIER
+OPTIONS_RADIO_MINIFIER= HJSMIN YUICOMPRESSOR
+
+MINIFIER_DESC= JavaScript sources minification
+YUICOMPRESSOR_DESC= Minify JavaScript with yuicompressor (Java)
+HJSMIN_DESC= Minify JavaScript with hjsmin (Haskell)
+
+YUICOMPRESSOR_BUILD_DEPENDS= yuicompressor:www/yuicompressor
+YUICOMPRESSOR_VARS= minifier=yuicompressor
+
+HJSMIN_BUILD_DEPENDS= hjsmin:www/hs-hjsmin
+HJSMIN_VARS= minifier=hjsmin
USE_PYTHON= noflavors
@@ -32,6 +38,12 @@ NO_ARCH= yes
NO_BUILD= yes
ETCDIR= ${PREFIX}/etc/xpra/html5-client
+.include <bsd.port.options.mk>
+
+.if !${PORT_OPTIONS:MYUICOMPRESSOR} && !${PORT_OPTIONS:MHJSMIN}
+MINIFIER= copy
+.endif
+
do-install:
cd ${WRKSRC} && ${PYTHON_CMD} setup.py install ${STAGEDIR} ${PREFIX}/share/xpra/www ${ETCDIR} ${MINIFIER}