aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorohauer <ohauer@FreeBSD.org>2014-03-10 02:09:55 +0800
committerohauer <ohauer@FreeBSD.org>2014-03-10 02:09:55 +0800
commitfd906296cd8640e55d3baeb983a30e736aa22c96 (patch)
treeb3e11c462979fd5768cbf654fc036b77aa200338
parentadf8b710e78d4a9d6b401399b570e990366553c1 (diff)
downloadfreebsd-ports-gnome-fd906296cd8640e55d3baeb983a30e736aa22c96.tar.gz
freebsd-ports-gnome-fd906296cd8640e55d3baeb983a30e736aa22c96.tar.zst
freebsd-ports-gnome-fd906296cd8640e55d3baeb983a30e736aa22c96.zip
- add stage support
-rw-r--r--www/mod_myvhost/Makefile28
-rw-r--r--www/mod_myvhost/files/patch-Makefile13
2 files changed, 22 insertions, 19 deletions
diff --git a/www/mod_myvhost/Makefile b/www/mod_myvhost/Makefile
index d12e8c332740..8b9a02da7de0 100644
--- a/www/mod_myvhost/Makefile
+++ b/www/mod_myvhost/Makefile
@@ -14,7 +14,6 @@ LICENSE= APACHE20
MANUAL_PACKAGE_BUILD= needs apr and apache with DBD options enabled
-
USE_APACHE= 22+
UNIQUENAME= ${PORTNAME}
@@ -28,7 +27,6 @@ OPTIONS_DEFAULT= PHP_MODULE
PHP_MODULE_DESC= Enable PHP
DEBUG_MODULE_DESC= Enable debugging
-NO_STAGE= yes
.include <bsd.port.options.mk>
.if ${PORT_OPTIONS:MDEBUG_MODULE}
@@ -39,24 +37,26 @@ STRIP= # keep debug information
.if ${PORT_OPTIONS:MPHP_MODULE}
MAKE_ENV+= WITH_PHP=true
USE_PHP= yes
-USE_PHP_MOD= yes
+WANT_PHP_MOD= yes
.endif
-.include <bsd.port.pre.mk>
-
pre-patch:
@${REINPLACE_CMD} -e "s|= apxs|= ${APXS}|" \
-e "s|= rm|= ${RM}|" -e "s|= ln|= ${LN}|" \
-e "s|= cp|= ${CP}|" ${WRKSRC}/Makefile
+post-patch:
+ ${REINPLACE_CMD} -e 's|@APXS_STAGE@|-S LIBEXECDIR=${STAGEDIR}${PREFIX}/${APACHEMODDIR}|' \
+ ${WRKSRC}/Makefile
+
+pre-install:
+ @${MKDIR} ${STAGEDIR}${PREFIX}/${APACHEMODDIR}
+
post-install:
-.if ${PORT_OPTIONS:MDOCS}
- @${MKDIR} ${DOCSDIR}
- @cd ${WRKSRC}/doc && ${INSTALL_DATA} ${PORTDOCS} ${DOCSDIR}
-.endif
-.if ${PORT_OPTIONS:MEXAMPLES}
- @${MKDIR} ${EXAMPLESDIR}
- @cd ${WRKSRC}/ && ${INSTALL_DATA} ${PORTEXAMPLES} ${EXAMPLESDIR}
-.endif
+ @${MKDIR} ${STAGEDIR}${DOCSDIR}
+ ${INSTALL_DATA} ${PORTDOCS:S|^|${WRKSRC}/doc/|} ${STAGEDIR}${DOCSDIR}
+
+ @${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
+ ${INSTALL_DATA} ${PORTEXAMPLES:S|^|${WRKSRC}/|} ${STAGEDIR}${EXAMPLESDIR}
-.include <bsd.port.post.mk>
+.include <bsd.port.mk>
diff --git a/www/mod_myvhost/files/patch-Makefile b/www/mod_myvhost/files/patch-Makefile
index 3d049f43ec17..e5f73f410039 100644
--- a/www/mod_myvhost/files/patch-Makefile
+++ b/www/mod_myvhost/files/patch-Makefile
@@ -1,6 +1,6 @@
---- ./Makefile.orig 2012-04-06 15:11:08.000000000 +0200
-+++ ./Makefile 2012-04-06 15:11:27.000000000 +0200
-@@ -16,8 +16,12 @@
+--- ./Makefile.orig 2014-03-09 18:49:26.000000000 +0100
++++ ./Makefile 2014-03-09 18:51:04.000000000 +0100
+@@ -16,10 +16,15 @@
CP = /bin/cp -f
CFLAGS = -Wc,-W -Wc,-Wall
@@ -12,15 +12,18 @@
+.endif
#CFLAGS+= -DWITH_PHP -DWITH_UID_GID -DWITH_CACHE
LDFLAGS =
++APXS_STAGE= @APXS_STAGE@
-@@ -28,8 +32,8 @@
+ default: all
+
+@@ -28,8 +33,8 @@
$(APACHE_MODULE): $(SRCS)
$(APXS) -c $(CFLAGS) $(LDFLAGS) $(SRCS)
-install: all
- $(APXS) -i -a -n $(NAME) $(MODULE_LA)
+install: $(MODULE_LA)
-+ $(APXS) -i -A -n $(NAME) $(MODULE_LA)
++ $(APXS) $(APXS_STAGE) -i -n $(NAME) $(MODULE_LA)
clean:
$(RM) $(OBJS) $(APACHE_MODULE) *.slo *.lo mod_myvhost.la .libs