aboutsummaryrefslogtreecommitdiffstats
path: root/deskutils/horde4-kronolith
diff options
context:
space:
mode:
authorthierry <thierry@FreeBSD.org>2006-01-06 08:38:13 +0800
committerthierry <thierry@FreeBSD.org>2006-01-06 08:38:13 +0800
commit922106489a63564790d516923e03c8fa28346fa9 (patch)
tree20dad146d367f92c711d016c12e8e3340824db6b /deskutils/horde4-kronolith
parent65a0f264588bfc3e5c26e6b14ba972c45fca49a3 (diff)
downloadfreebsd-ports-gnome-922106489a63564790d516923e03c8fa28346fa9.tar.gz
freebsd-ports-gnome-922106489a63564790d516923e03c8fa28346fa9.tar.zst
freebsd-ports-gnome-922106489a63564790d516923e03c8fa28346fa9.zip
- Replace WITH_APACHE2 by USE_APACHE, rename httpd.conf.xxx to
httpd-xxx.conf and fix configuration if APACHE_VERSION > 20. - Don't use the MCAL back-end by default for Kronolith, it is deprecated. - Deinstall bug reported by John Nielsen <john (at) jnielsen.net>: respect LHORDEDIR. - Fix horde-passwd installation / deinstallation. - Don't bump PORTREVISION, because running installations are not concerned.
Diffstat (limited to 'deskutils/horde4-kronolith')
-rw-r--r--deskutils/horde4-kronolith/Makefile25
-rw-r--r--deskutils/horde4-kronolith/files/pkg-deinstall.in (renamed from deskutils/horde4-kronolith/pkg-deinstall)2
-rw-r--r--deskutils/horde4-kronolith/files/pkg-message.in5
-rw-r--r--deskutils/horde4-kronolith/pkg-plist2
4 files changed, 21 insertions, 13 deletions
diff --git a/deskutils/horde4-kronolith/Makefile b/deskutils/horde4-kronolith/Makefile
index fe2d86b2bf40..32bae023c962 100644
--- a/deskutils/horde4-kronolith/Makefile
+++ b/deskutils/horde4-kronolith/Makefile
@@ -25,14 +25,14 @@ COMMENT= Kronolith is the Horde calendar application
#----------------------------------------------------------------------------
# You may define this option:
#
-# - WITHOUT_MCAL: you won't use the MCAL driver but a database backend
-# (only for PHP4).
+# - WITH_MCAL: you want to use the MCAL driver (deprecated, and only for PHP4).
#
#----------------------------------------------------------------------------
RUN_DEPENDS+= ${LOCALBASE}/${LHORDEDIR}/rpc.php:${PORTSDIR}/www/horde
NO_BUILD= yes
+USE_APACHE= 1.3+ # needed to test APACHE_VERSION
USE_PHP= yes # modules set by Horde, but needed to get PHP_VER
USE_REINPLACE= yes
@@ -46,18 +46,23 @@ LHORDEDIR?= www/horde
LKRONOLITHDIR?= ${LHORDEDIR}/kronolith
PKGMESSAGE= ${WRKDIR}/pkg-message
-SUB_FILES= pkg-message
+PKGDEINSTALL= ${WRKDIR}/pkg-deinstall
+SUB_FILES= pkg-message pkg-deinstall
SUB_LIST= KRONOLITHDIR=${KRONOLITHDIR}
-PLIST_SUB= KRONOLITHDIR=${LKRONOLITHDIR}
+PLIST_SUB= KRONOLITHDIR=${LKRONOLITHDIR} HORDE_INC=${HORDE_INC:S|^${LOCALBASE}/||}
KRONOLITHDIR= ${PREFIX}/${LKRONOLITHDIR}
CONFDIR= ${KRONOLITHDIR}/config
VAR_CAL= /var/calendar
-HORDE_INC= ${LOCALBASE}/etc/horde
-
.include <bsd.port.pre.mk>
+.if ${APACHE_VERSION} >= 20
+HORDE_INC= ${LOCALBASE}/etc/apache${APACHE_VERSION:S/20/2/}/Includes
+.else
+HORDE_INC= ${LOCALBASE}/etc/horde
+.endif
+
.if exists(${LOCALBASE}/sbin/htpasswd)
HTPASSWD= ${LOCALBASE}/sbin/htpasswd
.else
@@ -67,7 +72,7 @@ HTPASSWD= ${LOCALBASE}/bin/htpasswd
pre-configure:
@${RM} ${WRKSRC}/config/conf.xml.orig
@${SED} -e "s:/home/httpd/html/horde/kronolith:${KRONOLITHDIR}:" \
- ${FILESDIR}/httpd.conf.kronolith > ${WRKDIR}/httpd.conf.kronolith
+ ${FILESDIR}/httpd.conf.kronolith > ${WRKDIR}/httpd-kronolith.conf
do-install:
@${MKDIR} ${KRONOLITHDIR}
@@ -82,7 +87,7 @@ do-install:
.endfor
@${CHOWN} -R ${WWWOWN}:${WWWGRP} ${KRONOLITHDIR}
@${CHMOD} -R o-rwx ${CONFDIR}
- @${INSTALL_DATA} ${WRKDIR}/httpd.conf.kronolith ${HORDE_INC}
+ @${INSTALL_DATA} ${WRKDIR}/httpd-kronolith.conf ${HORDE_INC}
.if !defined(NOPORTDOCS)
@${MKDIR} ${DOCSDIR}
.for FILE in ${DOCS}
@@ -92,13 +97,13 @@ do-install:
.endif
post-install:
-.if !defined(WITHOUT_MCAL) && (${PHP_VER} == 4)
+.if defined(WITH_MCAL) && (${PHP_VER} == 4)
@if [ ! -d ${VAR_CAL} ]; then \
${ECHO_MSG} "===> Creating ${VAR_CAL}" ; \
${MKDIR} ${VAR_CAL} ; \
${CHMOD} 1777 ${VAR_CAL} ; \
fi
-.if !defined(BATCH)
+. if !defined(BATCH)
@if [ ! -f ${LOCALBASE}/etc/mpasswd ] ; then \
${ECHO_MSG} "===> Creating ${LOCALBASE}/etc/mpasswd" ; \
${ECHO} -n "Please enter a password for www's calendar: " ; \
diff --git a/deskutils/horde4-kronolith/pkg-deinstall b/deskutils/horde4-kronolith/files/pkg-deinstall.in
index 4578da3f26fe..896c740dd4da 100644
--- a/deskutils/horde4-kronolith/pkg-deinstall
+++ b/deskutils/horde4-kronolith/files/pkg-deinstall.in
@@ -9,7 +9,7 @@ if [ x$2 != xDEINSTALL ]; then
fi
if [ -z "${PACKAGE_BUILDING}" ]; then
- for cf in `ls ${PKG_PREFIX}/www/horde/kronolith/config/*php`; do
+ for cf in `ls %%KRONOLITHDIR%%/config/*php`; do
diff -bBqw $cf $cf.dist >/dev/null 2>&1
case $? in
0) # original config file, will be deleted by pkg-plist
diff --git a/deskutils/horde4-kronolith/files/pkg-message.in b/deskutils/horde4-kronolith/files/pkg-message.in
index e7f0e3401e17..54946bd7d451 100644
--- a/deskutils/horde4-kronolith/files/pkg-message.in
+++ b/deskutils/horde4-kronolith/files/pkg-message.in
@@ -5,7 +5,7 @@ blank configuration files.
Horde must be configured; if not, see `pkg_info -D -x horde'.
With PHP4:
-If you choose the mcal backend, libmcal must be configured with the driver
+If you choosed the mcal backend, libmcal must be configured with the driver
mstore for the user www:
- mkdir /var/calendar
@@ -21,6 +21,9 @@ SQL scripts in %%KRONOLITHDIR%%/scripts/sql.
WARNING! if you are upgrading from Kronolith v. 1.1.x, you have to alter
******** your schemas.
Please read the doc %%DOCSDIR%%/UPGRADING.
+ Please note that the MCAL back-end is deprecated!
+ To migrate from MCAL to SQL, you can use the provided script
+ %%KRONOLITHDIR%%/scripts/migrate_to_sql_driver.php
Finally, you must login to Horde as a Horde Administrator to finish the
configuration.
diff --git a/deskutils/horde4-kronolith/pkg-plist b/deskutils/horde4-kronolith/pkg-plist
index 46df1c3d2b06..bfee675d8a50 100644
--- a/deskutils/horde4-kronolith/pkg-plist
+++ b/deskutils/horde4-kronolith/pkg-plist
@@ -195,7 +195,7 @@
%%KRONOLITHDIR%%/viewevent.php
%%KRONOLITHDIR%%/week.php
%%KRONOLITHDIR%%/workweek.php
-etc/horde/httpd.conf.kronolith
+%%HORDE_INC%%/httpd-kronolith.conf
%%PORTDOCS%%@dirrm %%DOCSDIR%%
@dirrm %%KRONOLITHDIR%%/themes/simplex
@dirrm %%KRONOLITHDIR%%/themes/print