diff options
author | Yen-Ming Lee <leeym@FreeBSD.org> | 2005-05-13 15:15:31 +0000 |
---|---|---|
committer | Yen-Ming Lee <leeym@FreeBSD.org> | 2005-05-13 15:15:31 +0000 |
commit | 845a3332a0f555aca4deec740a2459243c2fcf46 (patch) | |
tree | 6c1628ce8da335f372802d6f3841fd40b065c33d /mail/openwebmail | |
parent | f7a7670b72cd42f56841564a5ce48ef1ea11851c (diff) | |
download | ports-845a3332a0f555aca4deec740a2459243c2fcf46.tar.gz ports-845a3332a0f555aca4deec740a2459243c2fcf46.zip |
- keep public addressbook and calendar if they are modified
Noticed by: tim@dnes.mlc.edu.tw
Notes
Notes:
svn path=/head/; revision=135190
Diffstat (limited to 'mail/openwebmail')
-rw-r--r-- | mail/openwebmail/Makefile | 5 | ||||
-rw-r--r-- | mail/openwebmail/pkg-deinstall | 6 | ||||
-rw-r--r-- | mail/openwebmail/pkg-install | 8 |
3 files changed, 19 insertions, 0 deletions
diff --git a/mail/openwebmail/Makefile b/mail/openwebmail/Makefile index fdd2eefe6903..3b93be31fb83 100644 --- a/mail/openwebmail/Makefile +++ b/mail/openwebmail/Makefile @@ -136,6 +136,11 @@ RUN_DEPENDS+= ${LOCALBASE}/bin/wget:${PORTSDIR}/ftp/wget-devel RUN_DEPENDS+= ${SITE_PERL}/${PERL_ARCH}/Compress/Zlib.pm:${PORTSDIR}/archivers/p5-Compress-Zlib .endif +post-extract: +.for x in addressbooks/global calendar.book + @${RM} ${WRKSRC}/cgi-bin/openwebmail/etc/${x} +.endfor + post-patch: .if defined(DISABLE_SPEEDYCGI) @${ECHO_MSG} "" diff --git a/mail/openwebmail/pkg-deinstall b/mail/openwebmail/pkg-deinstall index 895d43b968bc..a63d9953a511 100644 --- a/mail/openwebmail/pkg-deinstall +++ b/mail/openwebmail/pkg-deinstall @@ -3,4 +3,10 @@ if [ "$2" != "DEINSTALL" ]; then exit 0 fi +for x in addressbooks/global calendar.book; do + if [ ! -s "${PKG_PREFIX}/www/cgi-bin/openwebmail/etc/${x}" ]; then + rm ${PKG_PREFIX}/www/cgi-bin/openwebmail/etc/${x} + fi +done + rm -fr ${PKG_PREFIX}/www/cgi-bin/openwebmail/etc/sessions/* diff --git a/mail/openwebmail/pkg-install b/mail/openwebmail/pkg-install index fc74006d6cea..6d9a1f5a24b3 100644 --- a/mail/openwebmail/pkg-install +++ b/mail/openwebmail/pkg-install @@ -8,4 +8,12 @@ chmod 0770 ${PKG_PREFIX}/www/cgi-bin/openwebmail/etc/sessions mkdir -p ${PKG_PREFIX}/www/cgi-bin/openwebmail/etc/users chmod 0700 ${PKG_PREFIX}/www/cgi-bin/openwebmail/etc/users chmod 4755 ${PKG_PREFIX}/www/cgi-bin/openwebmail/openwebmail*pl + +for x in addressbooks/global calendar.book; do + if [ ! -s "${PKG_PREFIX}/www/cgi-bin/openwebmail/etc/${x}" ]; then + touch ${PKG_PREFIX}/www/cgi-bin/openwebmail/etc/${x} + chmod 0666 ${PKG_PREFIX}/www/cgi-bin/openwebmail/etc/${x} + fi +done + ${PKG_PREFIX}/www/cgi-bin/openwebmail/openwebmail-tool.pl --init --no |