Bug 190014 - [patch] Add staging support to www/bblog
Summary: [patch] Add staging support to www/bblog
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Steve Wills
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-05-20 16:40 UTC by joe
Modified: 2014-05-25 06:20 UTC (History)
0 users

See Also:


Attachments
file.diff (2.88 KB, patch)
2014-05-20 16:40 UTC, joe
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description joe 2014-05-20 16:40:00 UTC
Adds staging support to www/bblog.

Fix: Patch attached with submission follows:
Comment 1 Edwin Groothuis freebsd_committer 2014-05-20 16:40:07 UTC
Responsible Changed
From-To: freebsd-ports-bugs->swills

swills@ wants this submitter's PRs (via the GNATS Auto Assign Tool)
Comment 2 dfilter service freebsd_committer 2014-05-25 06:10:25 UTC
Author: miwi
Date: Sun May 25 05:10:20 2014
New Revision: 355111
URL: http://svnweb.freebsd.org/changeset/ports/355111
QAT: https://qat.redports.org/buildarchive/r355111/

Log:
  - Stage support
  
  PR:		190014
  Submitted by:	Joseph Benden <joe@thrallingpenguin.com

Modified:
  head/www/bblog/Makefile
  head/www/bblog/pkg-plist

Modified: head/www/bblog/Makefile
==============================================================================
--- head/www/bblog/Makefile	Sun May 25 05:09:50 2014	(r355110)
+++ head/www/bblog/Makefile	Sun May 25 05:10:20 2014	(r355111)
@@ -27,7 +27,6 @@ OPTIONS_DEFINE=	GD IMAGICK
 OPTIONS_DEFAULT=GD
 IMAGICK_DESC=	${IMAGEMAGICK_DESC}
 
-NO_STAGE=	yes
 .include <bsd.port.pre.mk>
 
 .if ${PORT_OPTIONS:MGD}
@@ -44,18 +43,19 @@ pre-patch:
 .endif
 
 do-install:
-	@${MKDIR} ${PREFIX}/${BBLOGDIR}/${PORTNAME:tl}
-	@${CHOWN} ${WWWOWN}:${WWWGRP} ${PREFIX}/${BBLOGDIR}
-	@${CHGRP} -R ${WWWGRP} ${PREFIX}/${BBLOGDIR}
-	@${CHMOD} 755 ${PREFIX}/${BBLOGDIR}
+	@${MKDIR} ${STAGEDIR}${PREFIX}/${BBLOGDIR}/${PORTNAME:tl}
+	@${CHOWN} ${WWWOWN}:${WWWGRP} ${STAGEDIR}${PREFIX}/${BBLOGDIR}
+	@${CHGRP} -R ${WWWGRP} ${STAGEDIR}${PREFIX}/${BBLOGDIR}
+	@${CHMOD} 755 ${STAGEDIR}${PREFIX}/${BBLOGDIR}
 .for f in archives.php documentation.txt htaccess-cleanurls index.php item rss.php search.php section
-	${INSTALL_DATA} ${WRKDIR}/${f} ${PREFIX}/${BBLOGDIR}
+	${INSTALL_DATA} ${WRKDIR}/${f} ${STAGEDIR}${PREFIX}/${BBLOGDIR}
 .endfor
-	@${CP} -Rv ${WRKSRC}/* ${PREFIX}/${BBLOGDIR}/${PORTNAME:tl}
-	@${CHMOD} 775 ${PREFIX}/${BBLOGDIR}/${PORTNAME:tl}/compiled_templates/
-	@${CHMOD} 775 ${PREFIX}/${BBLOGDIR}/${PORTNAME:tl}/cache/
-	@${CHMOD} 775 ${PREFIX}/${BBLOGDIR}/${PORTNAME:tl}/cache/favorites.xml
-	@${CHMOD} 775 ${PREFIX}/${BBLOGDIR}/${PORTNAME:tl}/config.php
+	@${CP} -Rv ${WRKSRC}/* ${STAGEDIR}${PREFIX}/${BBLOGDIR}/${PORTNAME:tl}
+	@${CHMOD} 775 ${STAGEDIR}${PREFIX}/${BBLOGDIR}/${PORTNAME:tl}/compiled_templates/
+	@${CHMOD} 775 ${STAGEDIR}${PREFIX}/${BBLOGDIR}/${PORTNAME:tl}/cache/
+	@${CHMOD} 775 ${STAGEDIR}${PREFIX}/${BBLOGDIR}/${PORTNAME:tl}/cache/favorites.xml
+	@${CHMOD} 775 ${STAGEDIR}${PREFIX}/${BBLOGDIR}/${PORTNAME:tl}/config.php
+	@${MV} ${STAGEDIR}${PREFIX}/${BBLOGDIR}/${PORTNAME:tl}/config.php ${STAGEDIR}${PREFIX}/${BBLOGDIR}/${PORTNAME:tl}/config.php.sample
 
 post-install:
 	@${CAT} ${PKGMESSAGE}

Modified: head/www/bblog/pkg-plist
==============================================================================
--- head/www/bblog/pkg-plist	Sun May 25 05:09:50 2014	(r355110)
+++ head/www/bblog/pkg-plist	Sun May 25 05:10:20 2014	(r355111)
@@ -1,3 +1,5 @@
+@owner %%WWWOWN%%
+@group %%WWWGRP%%
 %%WWWDOCROOT%%/%%BBLOGURL%%/archives.php
 %%WWWDOCROOT%%/%%BBLOGURL%%/bblog/bBlog_plugins/admin.comments.php
 %%WWWDOCROOT%%/%%BBLOGURL%%/bblog/bBlog_plugins/admin.links.php
@@ -52,7 +54,9 @@
 %%WWWDOCROOT%%/%%BBLOGURL%%/bblog/bblog.css
 %%WWWDOCROOT%%/%%BBLOGURL%%/bblog/cache/favorites.xml
 %%WWWDOCROOT%%/%%BBLOGURL%%/bblog/compiled_templates/this_file_is_here_so_the_directory_is_extracted
-%%WWWDOCROOT%%/%%BBLOGURL%%/bblog/config.php
+@unexec if cmp -s %D/%%WWWDOCROOT%%/%%BBLOGURL%%/bblog/config.php %D/%%WWWDOCROOT%%/%%BBLOGURL%%/bblog/config.php.sample; then rm -f %D/%%WWWDOCROOT%%/%%BBLOGURL%%/bblog/config.php; fi
+%%WWWDOCROOT%%/%%BBLOGURL%%/bblog/config.php.sample
+@exec cp -n %D/%F %B/config.php
 %%WWWDOCROOT%%/%%BBLOGURL%%/bblog/cp.css
 %%WWWDOCROOT%%/%%BBLOGURL%%/bblog/docs/LICENCE.txt
 %%WWWDOCROOT%%/%%BBLOGURL%%/bblog/docs/README.txt
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 3 Martin Wilke freebsd_committer 2014-05-25 06:11:32 UTC
State Changed
From-To: open->closed

Committed. Thanks!