ports/mail/postfixadmin/Makefile
Stefan Eßer b7f05445c0 Add WWW entries to port Makefiles
It has been common practice to have one or more URLs at the end of the
ports' pkg-descr files, one per line and prefixed with "WWW:". These
URLs should point at a project website or other relevant resources.

Access to these URLs required processing of the pkg-descr files, and
they have often become stale over time. If more than one such URL was
present in a pkg-descr file, only the first one was tarnsfered into
the port INDEX, but for many ports only the last line did contain the
port specific URL to further information.

There have been several proposals to make a project URL available as
a macro in the ports' Makefiles, over time.

This commit implements such a proposal and moves one of the WWW: entries
of each pkg-descr file into the respective port's Makefile. A heuristic
attempts to identify the most relevant URL in case there is more than
one WWW: entry in some pkg-descr file. URLs that are not moved into the
Makefile are prefixed with "See also:" instead of "WWW:" in the pkg-descr
files in order to preserve them.

There are 1256 ports that had no WWW: entries in pkg-descr files. These
ports will not be touched in this commit.

The portlint port has been adjusted to expect a WWW entry in each port
Makefile, and to flag any remaining "WWW:" lines in pkg-descr files as
deprecated.

Approved by:		portmgr (tcberner)
2022-09-07 23:10:59 +02:00

82 lines
2.4 KiB
Makefile

PORTNAME= postfixadmin
DISTVERSIONPREFIX= postfixadmin-
DISTVERSION= 3.4.dev.20211018
CATEGORIES= mail www
.if defined(_PFA_LITE)
PKGNAMESUFFIX= -lite${PHP_PKGNAMESUFFIX}
.else
PKGNAMESUFFIX= ${PHP_PKGNAMESUFFIX}
.endif
MAINTAINER= ports.maintainer@evilphi.com
COMMENT= PHP web-based management tool for Postfix virtual domains and users
WWW= http://www.postfixadmin.org/
LICENSE= GPLv2+
LICENSE_FILE= ${WRKSRC}/GPL-LICENSE.TXT
USES= cpe php:flavors shebangfix
CPE_VENDOR= postfix_admin_project
CPE_PRODUCT= postfix_admin
USE_GITHUB= yes
GH_TAGNAME= d3bc1551
USE_PHP= mbstring openssl pcre session spl
NO_ARCH= yes
NO_BUILD= yes
SUB_FILES+= pkg-message
PLIST_SUB= WWWGRP=${WWWGRP} \
WWWOWN=${WWWOWN}
OPTIONS_DEFINE= ADDONS DOCS IMAP
.if defined(_PFA_LITE)
OPTIONS_DEFAULT= SQLITE
.else
OPTIONS_DEFAULT= ADDONS IMAP SQLITE
.endif
OPTIONS_MULTI= DATABASE
OPTIONS_MULTI_DATABASE= MYSQL PGSQL SQLITE
OPTIONS_SUB= yes
ADDONS_DESC= Include add-ons and related Perl dependencies
IMAP_DESC= Support automated sub-folder creation for new mailboxes
ADDONS_RUN_DEPENDS= p5-DBI>=1.634:databases/p5-DBI \
p5-Email-Sender>=1.300031:mail/p5-Email-Sender \
p5-Email-Simple>=1.998:mail/p5-Email-Simple \
p5-Email-Valid>=0.12:mail/p5-Email-Valid \
p5-LockFile-Simple>=0.208:devel/p5-LockFile-Simple \
p5-Log-Log4perl>=0.26:devel/p5-Log-Log4perl \
p5-MIME-EncWords>=0.040:mail/p5-MIME-EncWords \
p5-Net-DNS>=1.32:dns/p5-Net-DNS \
p5-Try-Tiny>=0.30:lang/p5-Try-Tiny
ADDONS_USES= gettext perl5
IMAP_USE= PHP=imap
MYSQL_USE= PHP=pdo_mysql
PGSQL_USE= PHP=pdo_pgsql
SQLITE_USE= PHP=pdo_sqlite
do-install:
${MKDIR} ${STAGEDIR}${WWWDIR}
${MKDIR} ${STAGEDIR}${WWWDIR}/templates_c
${INSTALL_DATA} ${WRKSRC}/*.php ${STAGEDIR}${WWWDIR}
.for i in configs languages lib model public scripts templates tests
(cd ${WRKSRC}/${i} && ${COPYTREE_SHARE} . ${STAGEDIR}${WWWDIR}/${i})
.endfor
${MKDIR} ${STAGEDIR}${DATADIR}
.for i in GPL-LICENSE.TXT LICENSE.TXT password_expiration.sql postfixadmin.my.cnf
${INSTALL_DATA} ${WRKSRC}/${i} ${STAGEDIR}${DATADIR}
.endfor
do-install-ADDONS-on:
(cd ${WRKSRC}/ADDITIONS && ${COPYTREE_SHARE} . ${STAGEDIR}${DATADIR}/ADDITIONS)
(cd ${WRKSRC}/VIRTUAL_VACATION && ${COPYTREE_SHARE} . ${STAGEDIR}${DATADIR}/VIRTUAL_VACATION)
do-install-DOCS-on:
(cd ${WRKSRC}/DOCUMENTS && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR})
.for i in CHANGELOG.TXT INSTALL.TXT README.md
${INSTALL_DATA} ${WRKSRC}/${i} ${STAGEDIR}${DOCSDIR}
.endfor
.include <bsd.port.mk>