aboutsummaryrefslogtreecommitdiffstats
path: root/www/baikal
diff options
context:
space:
mode:
authoradamw <adamw@FreeBSD.org>2013-10-26 23:14:28 +0800
committeradamw <adamw@FreeBSD.org>2013-10-26 23:14:28 +0800
commit6a32283c53949269efcf82b98e8ba3941aa9e669 (patch)
treefaafdc652d59495da5e77de8f40c4528175ebe06 /www/baikal
parent0dee5d52e20f4f86fe3295478c0c7d757feae433 (diff)
downloadfreebsd-ports-gnome-6a32283c53949269efcf82b98e8ba3941aa9e669.tar.gz
freebsd-ports-gnome-6a32283c53949269efcf82b98e8ba3941aa9e669.tar.zst
freebsd-ports-gnome-6a32283c53949269efcf82b98e8ba3941aa9e669.zip
Handle docs and examples in the stage-way.
Handle default database creation in a better way. Don't install yet another copy of the GPL3 license. PORTREVISION bump for plist changes. Drop maintainership.
Diffstat (limited to 'www/baikal')
-rw-r--r--www/baikal/Makefile17
-rw-r--r--www/baikal/pkg-plist10
2 files changed, 15 insertions, 12 deletions
diff --git a/www/baikal/Makefile b/www/baikal/Makefile
index 98e7c2c1cde5..a14d4a670f71 100644
--- a/www/baikal/Makefile
+++ b/www/baikal/Makefile
@@ -3,12 +3,13 @@
PORTNAME= baikal
PORTVERSION= 0.2.6
+PORTREVISION= 1
CATEGORIES= www
MASTER_SITES= http://baikal-server.com/get/
DISTNAME= ${PORTNAME}-regular-${PORTVERSION}
EXTRACT_SUFX= .tgz
-MAINTAINER= adamw@FreeBSD.org
+MAINTAINER= ports@FreeBSD.org
COMMENT= Lightweight CalDAV/CardDAV server
LICENSE= GPLv3
@@ -18,13 +19,8 @@ USE_PHP= ctype filter xml pdo_sqlite session mbstring dom
WRKSRC= ${WRKDIR}/${PORTNAME}-regular
NO_BUILD= yes
-PLIST_SUB+= CALDB="${WWWDIR}/Specific/db/db.sqlite"
-SUB_LIST+= CALDB="${WWWDIR}/Specific/db/db.sqlite"
SUB_FILES= pkg-install pkg-message
-PORTDOCS= *
-PORTEXAMPLES= *
-
.include <bsd.port.options.mk>
post-patch:
${FIND} ${WRKSRC} -type f -not -name '*.php' -exec ${CHMOD} ${SHAREMODE} {} \;
@@ -34,6 +30,7 @@ post-patch:
${WRKSRC}/Specific/db/db.sqlite-dist
${CHMOD} 644 ${WRKSRC}/Specific/db/db.sqlite-dist
# I can't decide whether to include this file or forbid it.
+# It's probably better to make remote configuration opt-in.
# ${ECHO_CMD} "platypus" > ${WRKSRC}/Specific/ENABLE_INSTALL
${RM} -f ${WRKSRC}/Specific/ENABLE_INSTALL
${REINPLACE_CMD} -e 's,/var/www/dav.mydomain.com,${WWWDIR},g' \
@@ -47,17 +44,15 @@ do-install:
.endfor
cd ${WRKSRC} && ${FIND} Specific -not -path '*/virtualhosts*' | \
${CPIO} -pdmu -R ${WWWOWN}:${WWWGRP} --quiet ${STAGEDIR}${WWWDIR}
-.if ${PORT_OPTIONS:MDOCS}
+
${MKDIR} ${STAGEDIR}${DOCSDIR}
-.for f in INSTALL.md LICENSE.txt README.md TROUBLESHOOTING.md
+.for f in INSTALL.md README.md TROUBLESHOOTING.md
${INSTALL_DATA} ${WRKSRC}/$f ${STAGEDIR}${DOCSDIR}
.endfor
-.endif
-.if ${PORT_OPTIONS:MEXAMPLES}
+
${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
.for f in apache2 nginx
${INSTALL_DATA} ${WRKSRC}/Specific/virtualhosts/baikal.$f ${STAGEDIR}${EXAMPLESDIR}
.endfor
-.endif
.include <bsd.port.mk>
diff --git a/www/baikal/pkg-plist b/www/baikal/pkg-plist
index 052b1c40c263..c8ae25e1e3fa 100644
--- a/www/baikal/pkg-plist
+++ b/www/baikal/pkg-plist
@@ -301,8 +301,9 @@
%%WWWDIR%%/Core/Resources/Web/TwitterBootstrap
%%WWWDIR%%/Specific/.htaccess
@rmtry %%WWWDIR%%/Specific/ENABLE_INSTALL
-@unexec if test -f %%CALDB%% && cmp -s %%CALDB%%-dist %%CALDB%%; then /bin/rm -f %%CALDB%%; fi
+@unexec if cmp -s %D/Specific/db/db.sqlite-dist %D/Specific/db/db.sqlite; then rm -f %D/Specific/db/db.sqlite; fi
%%WWWDIR%%/Specific/db/db.sqlite-dist
+@exec if [ ! -f %D/Specific/db/db.sqlite ]; then cp -p %D/%F %B/Specific/db/db.sqlite; fi
%%WWWDIR%%/html/.htaccess
%%WWWDIR%%/html/admin/index.php
%%WWWDIR%%/html/admin/install/index.php
@@ -995,3 +996,10 @@
@dirrm %%WWWDIR%%/Core/Frameworks
@dirrm %%WWWDIR%%/Core
@dirrmtry %%WWWDIR%%
+%%PORTDOCS%%%%DOCSDIR%%/INSTALL.md
+%%PORTDOCS%%%%DOCSDIR%%/README.md
+%%PORTDOCS%%%%DOCSDIR%%/TROUBLESHOOTING.md
+%%PORTDOCS%%@dirrm %%DOCSDIR%%
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/baikal.apache2
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/baikal.nginx
+%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%