From 82bd92c0873e9ea142829c2119a8091440576b61 Mon Sep 17 00:00:00 2001 From: "Sergey A. Osokin" Date: Tue, 7 Dec 2004 09:07:43 +0000 Subject: Update to 0.1.12. Fix link to WWWDATA directory (test link exist before make link). Add two new knobs: START_AFTER_INSTALL and STOP_BEFORE_REMOVE. --- www/nginx-devel/Makefile | 24 +++++++++++++++++++----- www/nginx-devel/distinfo | 4 ++-- www/nginx-devel/pkg-plist | 5 +++++ www/nginx/Makefile | 24 +++++++++++++++++++----- www/nginx/distinfo | 4 ++-- www/nginx/pkg-plist | 5 +++++ 6 files changed, 52 insertions(+), 14 deletions(-) (limited to 'www') diff --git a/www/nginx-devel/Makefile b/www/nginx-devel/Makefile index 2ba3a524d634..76a038c676a7 100644 --- a/www/nginx-devel/Makefile +++ b/www/nginx-devel/Makefile @@ -6,7 +6,7 @@ # PORTNAME= nginx -PORTVERSION= 0.1.11 +PORTVERSION= 0.1.12 CATEGORIES= www MASTER_SITES= http://sysoev.ru/nginx/ @@ -46,9 +46,17 @@ PLIST_SUB+= WWWDATA="@comment " PLIST_SUB+= WWWDATA="" .endif -PLIST_FILES+= etc/nginx/koi-win \ - etc/rc.d/nginx.sh \ - sbin/nginx +.if defined(STOP_BEFORE_REMOVE) +PLIST_SUB+= STOP_BEFORE_REMOVE="" +.else +PLIST_SUB+= STOP_BEFORE_REMOVE="@comment " +.endif + +.if defined(START_AFTER_INSTALL) +PLIST_SUB+= START_AFTER_INSTALL="" +.else +PLIST_SUB+= START_AFTER_INSTALL="@comment " +.endif RC_SCRIPTS_SUB=PREFIX=${PREFIX} RC_SUBR=${RC_SUBR} @@ -78,7 +86,13 @@ do-install: ${MKDIR} ${PREFIX}/www/nginx-dist ${INSTALL_DATA} ${WRKSRC}/html/index.html ${PREFIX}/www/nginx-dist ${ECHO_CMD} "" >>${PREFIX}/www/nginx-dist/EXAMPLE_DIRECTORY-DONT_ADD_OR_TOUCH_ANYTHING - ${LN} -sf ${PREFIX}/www/nginx-dist ${PREFIX}/www/nginx + [ -e ${PREFIX}/www/nginx ] || \ + ${LN} -sf ${PREFIX}/www/nginx-dist ${PREFIX}/www/nginx +.endif + +post-install: +.if defined(START_AFTER_INSTALL) + ${PREFIX}/etc/rc.d/nginx.sh start .endif .include diff --git a/www/nginx-devel/distinfo b/www/nginx-devel/distinfo index f2966cdd6d82..67229b3422fe 100644 --- a/www/nginx-devel/distinfo +++ b/www/nginx-devel/distinfo @@ -1,2 +1,2 @@ -MD5 (nginx-0.1.11.tar.gz) = a0fe15f59b0923c5d086b147f8c6bd0e -SIZE (nginx-0.1.11.tar.gz) = 241476 +MD5 (nginx-0.1.12.tar.gz) = ef7ab5ea8ed4837b01559977a409f310 +SIZE (nginx-0.1.12.tar.gz) = 241950 diff --git a/www/nginx-devel/pkg-plist b/www/nginx-devel/pkg-plist index 543e40b9de3d..c9ab18f7b2b3 100644 --- a/www/nginx-devel/pkg-plist +++ b/www/nginx-devel/pkg-plist @@ -1,4 +1,5 @@ @comment $FreeBSD$ +etc/nginx/koi-win @unexec if cmp -s %D/etc/nginx/mime.types %D/etc/nginx/mime.types-dist; then rm -f %D/etc/nginx/mime.types; fi etc/nginx/mime.types-dist @exec [ -f %B/mime.types ] || cp %B/%f %B/mime.types @@ -14,3 +15,7 @@ etc/nginx/nginx.conf-dist %%WWWDATA%%@exec chmod a-w www/nginx-dist %%WWWDATA%%@unexec if [ -L %D/www/nginx ]; then rm -f %D/www/nginx; fi %%WWWDATA%%@dirrm www/nginx-dist +%%STOP_BEFORE_REMOVE%%@unexec %D/etc/rc.d/nginx.sh stop || true +sbin/nginx +etc/rc.d/nginx.sh +%%START_AFTER_INSTALL%%@exec %D/etc/rc.d/nginx.sh start diff --git a/www/nginx/Makefile b/www/nginx/Makefile index 2ba3a524d634..76a038c676a7 100644 --- a/www/nginx/Makefile +++ b/www/nginx/Makefile @@ -6,7 +6,7 @@ # PORTNAME= nginx -PORTVERSION= 0.1.11 +PORTVERSION= 0.1.12 CATEGORIES= www MASTER_SITES= http://sysoev.ru/nginx/ @@ -46,9 +46,17 @@ PLIST_SUB+= WWWDATA="@comment " PLIST_SUB+= WWWDATA="" .endif -PLIST_FILES+= etc/nginx/koi-win \ - etc/rc.d/nginx.sh \ - sbin/nginx +.if defined(STOP_BEFORE_REMOVE) +PLIST_SUB+= STOP_BEFORE_REMOVE="" +.else +PLIST_SUB+= STOP_BEFORE_REMOVE="@comment " +.endif + +.if defined(START_AFTER_INSTALL) +PLIST_SUB+= START_AFTER_INSTALL="" +.else +PLIST_SUB+= START_AFTER_INSTALL="@comment " +.endif RC_SCRIPTS_SUB=PREFIX=${PREFIX} RC_SUBR=${RC_SUBR} @@ -78,7 +86,13 @@ do-install: ${MKDIR} ${PREFIX}/www/nginx-dist ${INSTALL_DATA} ${WRKSRC}/html/index.html ${PREFIX}/www/nginx-dist ${ECHO_CMD} "" >>${PREFIX}/www/nginx-dist/EXAMPLE_DIRECTORY-DONT_ADD_OR_TOUCH_ANYTHING - ${LN} -sf ${PREFIX}/www/nginx-dist ${PREFIX}/www/nginx + [ -e ${PREFIX}/www/nginx ] || \ + ${LN} -sf ${PREFIX}/www/nginx-dist ${PREFIX}/www/nginx +.endif + +post-install: +.if defined(START_AFTER_INSTALL) + ${PREFIX}/etc/rc.d/nginx.sh start .endif .include diff --git a/www/nginx/distinfo b/www/nginx/distinfo index f2966cdd6d82..67229b3422fe 100644 --- a/www/nginx/distinfo +++ b/www/nginx/distinfo @@ -1,2 +1,2 @@ -MD5 (nginx-0.1.11.tar.gz) = a0fe15f59b0923c5d086b147f8c6bd0e -SIZE (nginx-0.1.11.tar.gz) = 241476 +MD5 (nginx-0.1.12.tar.gz) = ef7ab5ea8ed4837b01559977a409f310 +SIZE (nginx-0.1.12.tar.gz) = 241950 diff --git a/www/nginx/pkg-plist b/www/nginx/pkg-plist index 543e40b9de3d..c9ab18f7b2b3 100644 --- a/www/nginx/pkg-plist +++ b/www/nginx/pkg-plist @@ -1,4 +1,5 @@ @comment $FreeBSD$ +etc/nginx/koi-win @unexec if cmp -s %D/etc/nginx/mime.types %D/etc/nginx/mime.types-dist; then rm -f %D/etc/nginx/mime.types; fi etc/nginx/mime.types-dist @exec [ -f %B/mime.types ] || cp %B/%f %B/mime.types @@ -14,3 +15,7 @@ etc/nginx/nginx.conf-dist %%WWWDATA%%@exec chmod a-w www/nginx-dist %%WWWDATA%%@unexec if [ -L %D/www/nginx ]; then rm -f %D/www/nginx; fi %%WWWDATA%%@dirrm www/nginx-dist +%%STOP_BEFORE_REMOVE%%@unexec %D/etc/rc.d/nginx.sh stop || true +sbin/nginx +etc/rc.d/nginx.sh +%%START_AFTER_INSTALL%%@exec %D/etc/rc.d/nginx.sh start -- cgit v1.2.3