Skip to content

Instantly share code, notes, and snippets.

@dch
Created September 8, 2016 05:07
Show Gist options
  • Save dch/28b707cdaa254916cf37d60fc71119f4 to your computer and use it in GitHub Desktop.
Save dch/28b707cdaa254916cf37d60fc71119f4 to your computer and use it in GitHub Desktop.
commit 5e2ba2fbef502a980564c9d47e2a9d9f1ef4115b
Author: Dave Cottlehuber <[email protected]>
Date: Mon Aug 15 21:06:08 2016 +0000
www/h2o: add mruby support by default
diff --git a/www/h2o/Makefile b/www/h2o/Makefile
index 5d4b022..35fef29 100644
--- a/www/h2o/Makefile
+++ b/www/h2o/Makefile
@@ -2,7 +2,7 @@
# $FreeBSD$
PORTNAME= h2o
-PORTVERSION= 2.0.1
+PORTVERSION= 2.0.2
DISTVERSIONPREFIX= v
CATEGORIES= www
@@ -35,14 +35,25 @@ H2O_LOGDIR= /var/log/${PORTNAME}/
USE_RC_SUBR= ${PORTNAME}
-OPTIONS_DEFINE= LIBRESSL
+OPTIONS_DEFINE= LIBRESSL MRUBY
+OPTIONS_SUB= yes
LIBRESSL_DESC= Build with bundled LibreSSL instead of OpenSSL
-OPTIONS_DEFAULT= LIBRESSL
+MRUBY_DESC= Build with mruby handler support
+
+OPTIONS_DEFAULT= LIBRESSL MRUBY
CMAKE_ARGS+= -DEXTRA_LIBRARIES=OFF -DWITHOUT_LIBS=ON
.include <bsd.port.options.mk>
+.if ${PORT_OPTIONS:MMRUBY}
+CMAKE_ARGS+= -DWITH_MRUBY=ON
+USE_RUBY= yes
+BUILD_DEPENDS+= bison:devel/bison
+.else
+CMAKE_ARGS+= -DWITH_MRUBY=OFF
+.endif
+
.if ${PORT_OPTIONS:MLIBRESSL}
CMAKE_ARGS+= -DWITH_BUNDLED_SSL=ON
WITH_OPENSSL_PORT= no
diff --git a/www/h2o/distinfo b/www/h2o/distinfo
index ab5cba0..34b15f3 100644
--- a/www/h2o/distinfo
+++ b/www/h2o/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1467186334
-SHA256 (h2o-h2o-v2.0.1_GH0.tar.gz) = c53d11589c8c76491cf3a940b649d0a9cb27c36eb276963811ac1bc16cd2bf2c
-SIZE (h2o-h2o-v2.0.1_GH0.tar.gz) = 15012563
+TIMESTAMP = 1471295307
+SHA256 (h2o-h2o-v2.0.2_GH0.tar.gz) = e9600aa8e99b2592bc4695ad482aba0546ac80c6c4cbbe294d0747563ddb64c5
+SIZE (h2o-h2o-v2.0.2_GH0.tar.gz) = 15014155
diff --git a/www/h2o/pkg-plist b/www/h2o/pkg-plist
index 43d002b..254a9c2 100644
--- a/www/h2o/pkg-plist
+++ b/www/h2o/pkg-plist
@@ -7,6 +7,7 @@ share/h2o/start_server
%%DATADIR%%/fastcgi-cgi
%%DATADIR%%/setuidgid
%%DATADIR%%/status/index.html
+%%MRUBY%%%%DATADIR%%/mruby/htpasswd.rb
@dir(%%H2O_USER%%,%%H2O_GROUP%%,0750) %%H2O_LOGDIR%%
%%PORTDOCS%%%%DOCSDIR%%/assets/8mbps100msec-nginx195-h2o150.png
%%PORTDOCS%%%%DOCSDIR%%/assets/firstpaintbench.png
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment