1 |
laffer1 |
592 |
# New ports collection makefile for: squirrelmail |
2 |
|
|
# Date created: 27 December 2001 |
3 |
|
|
# Whom: Simon Dick <simond@irrelevant.org> |
4 |
|
|
# |
5 |
|
|
# $FreeBSD: ports/mail/squirrelmail/Makefile,v 1.45 2006/08/11 16:28:19 clsung Exp $ |
6 |
laffer1 |
3679 |
# $MidnightBSD: mports/mail/squirrelmail/Makefile,v 1.4 2007/08/14 05:50:22 laffer1 Exp $ |
7 |
laffer1 |
592 |
# |
8 |
|
|
|
9 |
|
|
PORTNAME= squirrelmail |
10 |
laffer1 |
3679 |
PORTVERSION= 1.4.11 |
11 |
laffer1 |
592 |
CATEGORIES= mail www |
12 |
|
|
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE} |
13 |
|
|
MASTER_SITE_SUBDIR= ${PORTNAME} |
14 |
|
|
DISTFILES= ${DISTNAME}${EXTRACT_SUFX} \ |
15 |
laffer1 |
2286 |
all_locales-1.4.9-20070106${EXTRACT_SUFX} |
16 |
laffer1 |
592 |
DIST_SUBDIR= ${PORTNAME} |
17 |
|
|
|
18 |
|
|
MAINTAINER= ports@MidnightBSD.org |
19 |
|
|
COMMENT= A webmail system which accesses mail over IMAP |
20 |
|
|
|
21 |
|
|
USE_PHP= session mhash gettext mbstring pcre openssl xml |
22 |
|
|
WANT_PHP_WEB= yes |
23 |
|
|
|
24 |
|
|
USE_BZIP2= yes |
25 |
laffer1 |
604 |
USE_GETTEXT= yes |
26 |
laffer1 |
592 |
|
27 |
|
|
.ifdef WITH_DATABASE |
28 |
|
|
RUN_DEPENDS+= ${PREFIX}/share/pear/DB.php:${PORTSDIR}/databases/pear-DB |
29 |
|
|
.endif |
30 |
|
|
|
31 |
|
|
.ifdef WITH_LDAP |
32 |
|
|
USE_PHP+= ldap |
33 |
|
|
.endif |
34 |
|
|
|
35 |
|
|
.ifndef WITHOUT_WWWDIR |
36 |
|
|
SQUIRRELDIR?= ${PREFIX}/www/${PORTNAME} |
37 |
|
|
.else |
38 |
|
|
SQUIRRELDIR?= ${PREFIX}/${PORTNAME} |
39 |
|
|
.endif |
40 |
|
|
|
41 |
|
|
PLIST_SUB= PORTVERSION=${PORTVERSION} \ |
42 |
|
|
SQUIRRELDIR="${SQUIRRELDIR:S,^${PREFIX}/,,}" |
43 |
|
|
|
44 |
|
|
SUB_FILES= pkg-message pkg-install pkg-deinstall |
45 |
|
|
SUB_LIST= SQUIRRELDIR=${SQUIRRELDIR} |
46 |
|
|
|
47 |
|
|
PORTDOCS= * |
48 |
|
|
|
49 |
|
|
pre-everything:: |
50 |
|
|
@${ECHO_CMD} "SquirrelMail is installed into ${SQUIRRELDIR}" |
51 |
|
|
@${ECHO_CMD} "To use the old location ${PREFIX}/${PORTNAME} define" |
52 |
|
|
@${ECHO_CMD} "WITHOUT_WWWDIR when patching or installing" |
53 |
|
|
@${ECHO_CMD} |
54 |
|
|
@${ECHO_CMD} "Use WITH_LDAP to ensure PHP LDAP support is installed" |
55 |
|
|
@${ECHO_CMD} "Use WITH_DATABASE to ensure PEAR framework for database support is installed" |
56 |
|
|
@${ECHO_CMD} " (note that this does not install the database specific PEAR support, e.g. MySQL)" |
57 |
|
|
@${ECHO_CMD} |
58 |
|
|
|
59 |
|
|
post-patch: |
60 |
|
|
.ifndef PATCH_DEBUG |
61 |
|
|
@${RM} -f ${WRKSRC}/config/config_default.php.orig ${WRKSRC}/functions/global.php.orig |
62 |
|
|
.endif |
63 |
|
|
@${REINPLACE_CMD} -e 's|ispell|${LOCALBASE}/bin/ispell|g' \ |
64 |
|
|
${WRKSRC}/plugins/squirrelspell/sqspell_config.php |
65 |
|
|
@${RM} ${WRKSRC}/plugins/squirrelspell/sqspell_config.php.bak |
66 |
|
|
|
67 |
|
|
# Rearrange the documentation |
68 |
|
|
do-build: |
69 |
|
|
.for file in AUTHORS ChangeLog COPYING INSTALL README UPGRADE |
70 |
|
|
@${MV} ${WRKSRC}/${file} ${WRKSRC}/doc/ |
71 |
|
|
.endfor |
72 |
|
|
@${MV} ${WRKSRC}/ReleaseNotes ${WRKSRC}/doc/ReleaseNotes-${PORTVERSION}.txt |
73 |
|
|
@${MV} ${WRKSRC}/themes/README.themes ${WRKSRC}/doc/ |
74 |
|
|
@cd ${WRKSRC} ; for f in `find plugins -name "README*" -or \ |
75 |
|
|
-name INSTALL -or -name CHANGES -or -name HISTORY`; \ |
76 |
|
|
do \ |
77 |
|
|
${MKDIR} doc/`dirname $$f` ; \ |
78 |
|
|
${MV} $$f doc/`dirname $$f` ; \ |
79 |
|
|
done; \ |
80 |
|
|
${MV} doc/plugins/squirrelspell/doc/README doc/plugins/squirrelspell ; \ |
81 |
|
|
${RM} -rf doc/plugins/squirrelspell/doc ; \ |
82 |
|
|
${MV} plugins/squirrelspell/doc/* doc/plugins/squirrelspell ; \ |
83 |
|
|
${RM} -f doc/plugins/squirrelspell/index.php ; \ |
84 |
|
|
${RM} -rf plugins/squirrelspell/doc |
85 |
|
|
@${ECHO} "left_refresh=300" >> ${WRKSRC}/data/default_pref |
86 |
|
|
@${CP} -r ${WRKSRC}/../locale ${WRKSRC} |
87 |
|
|
@${CP} -r ${WRKSRC}/../images ${WRKSRC} |
88 |
|
|
@${CP} -r ${WRKSRC}/../help ${WRKSRC} |
89 |
|
|
|
90 |
|
|
do-install: |
91 |
|
|
${MKDIR} ${PREFIX}/etc/periodic/daily |
92 |
|
|
${INSTALL_SCRIPT} ${FILESDIR}/111.clean-squirrelmail ${PREFIX}/etc/periodic/daily |
93 |
|
|
${MKDIR} ${SQUIRRELDIR} |
94 |
|
|
@${CP} -pv ${WRKSRC}/index.php ${SQUIRRELDIR} |
95 |
|
|
@${CP} -pv ${WRKSRC}/configure ${SQUIRRELDIR} |
96 |
|
|
.for DIR in class config data functions help images include locale plugins po src themes |
97 |
|
|
@${CP} -rpv ${WRKSRC}/${DIR} ${SQUIRRELDIR} |
98 |
|
|
.endfor |
99 |
|
|
${CHOWN} -R ${WWWOWN}:${WWWGRP} ${SQUIRRELDIR}/data |
100 |
|
|
.if !defined(NOPORTDOCS) |
101 |
|
|
${MKDIR} ${DOCSDIR} |
102 |
|
|
@${CP} -Rv ${WRKSRC}/doc/* ${DOCSDIR} |
103 |
|
|
.endif |
104 |
|
|
|
105 |
|
|
|
106 |
|
|
.include <bsd.port.mk> |