aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSahil Tandon <sahil@FreeBSD.org>2014-06-29 18:31:49 +0000
committerSahil Tandon <sahil@FreeBSD.org>2014-06-29 18:31:49 +0000
commitdfaf5f8e99c6d2174b14e6050d8041c10a270f2d (patch)
treed17b33696ad18d98bbece5f340ae73324fcd266d
parent0241af3e58aa0e252c23f8e45e7393d9ed6e1cbf (diff)
downloadports-dfaf5f8e99c6d2174b14e6050d8041c10a270f2d.tar.gz
ports-dfaf5f8e99c6d2174b14e6050d8041c10a270f2d.zip
Notes
-rw-r--r--www/geeklog/Makefile20
-rw-r--r--www/geeklog/pkg-plist8
2 files changed, 14 insertions, 14 deletions
diff --git a/www/geeklog/Makefile b/www/geeklog/Makefile
index 7bceb50defb4..a1563a6dd3ec 100644
--- a/www/geeklog/Makefile
+++ b/www/geeklog/Makefile
@@ -16,24 +16,20 @@ USE_MYSQL= yes
NO_BUILD= yes
USE_PHP= yes
-NO_STAGE= yes
do-install:
- @${INSTALL} -o ${WWWOWN} -g ${WWWGRP} -m 555 -d ${WWWDIR}
+ @${INSTALL} -o ${WWWOWN} -g ${WWWGRP} -m 555 -d ${STAGEDIR}${WWWDIR}
@(cd ${WRKSRC} && \
- ${COPYTREE_SHARE} \* ${WWWDIR} "! -name db-config.php \
+ ${COPYTREE_SHARE} \* ${STAGEDIR}${WWWDIR} "! -name db-config.php \
-or -name siteconfig.php")
- @if [ ! -f ${WWWDIR}/db-config.php ]; then \
- ${INSTALL_DATA} ${WRKSRC}/db-config.php ${WWWDIR}/db-config.php; \
- fi
- @if [ ! -f ${WWWDIR}/public_html/siteconfig.php ]; then \
- {INSTALL_DATA} ${WRKSRC}/public_html/siteconfig.php \
- ${WWWDIR}/public_html/siteconfig.php; \
- fi
+ @${INSTALL_DATA} ${WRKSRC}/db-config.php ${STAGEDIR}${WWWDIR}/db-config.php.sample;
+ @${INSTALL_DATA} ${WRKSRC}/public_html/siteconfig.php \
+ ${STAGEDIR}${WWWDIR}/public_html/siteconfig.php.sample
+ @${RM} ${STAGEDIR}${WWWDIR}/public_html/siteconfig.php
post-install:
- @${CHOWN} -R ${WWWOWN}:${WWWGRP} ${WWWDIR}
+ @${CHOWN} -R ${WWWOWN}:${WWWGRP} ${STAGEDIR}${WWWDIR}
.for i in db-config.php error.log siteconfig.php geeklog.rss
- @${FIND} ${WWWDIR} -name ${i} | ${XARGS} ${CHMOD} 755
+ @${FIND} ${STAGEDIR}${WWWDIR} -name ${i} | ${XARGS} ${CHMOD} 755
.endfor
@${CAT} ${PKGMESSAGE}
diff --git a/www/geeklog/pkg-plist b/www/geeklog/pkg-plist
index 745b1f581c72..d3cbb3452fda 100644
--- a/www/geeklog/pkg-plist
+++ b/www/geeklog/pkg-plist
@@ -1,5 +1,9 @@
-@unexec if [ "`md5 -q %D/%%WWWDIR%%/db-config.php`" = "e152b8b4ebd7e8b5bf05c9466f618bfa" ]; then rm -f %D/%%WWWDIR%%/db-config.php; fi
-@unexec if [ "`md5 -q %D/%%WWWDIR%%/public_html/siteconfig.php`" = "a713c0e73d143db728d350010f7cf289" ]; then rm -f %D/%%WWWDIR%%/public_html/siteconfig.php; fi
+@unexec if cmp -s %D/%%WWWDIR%%/db-config.php %D/%%WWWDIR%%/db-config.php.sample; then rm -f %D/%%WWWDIR%%/db-config.php; fi
+%%WWWDIR%%/db-config.php.sample
+@exec cp -n %D/%F %B/db-config.php
+@unexec if cmp -s %D/%%WWWDIR%%/public_html/siteconfig.php %D/%%WWWDIR%%/public_html/siteconfig.php.sample; then rm -f %D/%%WWWDIR%%/public_html/siteconfig.php; fi
+%%WWWDIR%%/public_html/siteconfig.php.sample
+@exec cp -n %D/%F %B/siteconfig.php
%%WWWDIR%%/INSTALL
%%WWWDIR%%/backups/README
%%WWWDIR%%/data/README