1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-29 01:13:08 +00:00
freebsd-ports/www/mediawiki119/Makefile

83 lines
2.1 KiB
Makefile

# Created by: Gerrit Beine <tux@pinguru.net>
# $FreeBSD$
PORTNAME= mediawiki
PORTVERSION= 1.19.8
CATEGORIES= www
MASTER_SITES= http://dumps.wikimedia.org/mediawiki/${PORTVERSION:R}/
MAINTAINER= wen@FreeBSD.org
COMMENT= The wiki engine used by Wikipedia
LICENSE= GPLv2
CONFLICTS= mediawiki-1.2[0-9].*
FETCH_ARGS= -pr
NO_LATEST_LINK= yes
USE_PHP= ctype iconv mbstring pcre session xml zlib readline dom
IGNORE_WITH_PHP=4
WANT_PHP_WEB= yes
MEDIAWIKIDIR?= www/mediawiki
NO_BUILD= yes
OPTIONS_DEFINE= MYSQL PGSQL SQLITE LDAP MEMCACHED APC EACCEL XCACHE IMAGICK
OPTIONS_DEFAULT=MYSQL APC
MEMCACHED_DESC= use memcached
APC_DESC= use pecl-APC(Mediawiki recommended)
EACCEL_DESC= use eAccelerator (instead of pecl-APC)
XCACHE_DESC= use xCache (instead of pecl-APC)
IMAGICK_DESC= use ImageMagick
NO_STAGE= yes
.include <bsd.port.options.mk>
.if ${PORT_OPTIONS:MMYSQL}
USE_MYSQL= client
USE_PHP+= mysql
.endif
.if ${PORT_OPTIONS:MPGSQL}
USE_PHP+= pgsql
.endif
.if ${PORT_OPTIONS:MSQLITE}
USE_PHP+= sqlite3
.endif
.if ${PORT_OPTIONS:MLDAP}
USE_PHP+= ldap
.endif
.if ${PORT_OPTIONS:MMEMCACHED}
RUN_DEPENDS= memcached:${PORTSDIR}/databases/memcached
.endif
.if ${PORT_OPTIONS:MIMAGICK}
RUN_DEPENDS+= ${LOCALBASE}/lib/php/${PHP_EXT_DIR}/imagick.so:${PORTSDIR}/graphics/pecl-imagick
.endif
.if ${PORT_OPTIONS:MAPC}
RUN_DEPENDS+= ${LOCALBASE}/lib/php/${PHP_EXT_DIR}/apc.so:${PORTSDIR}/www/pecl-APC
.elif ${PORT_OPTIONS:MEACCEL}
RUN_DEPENDS+= ${LOCALBASE}/lib/php/${PHP_EXT_DIR}/eaccelerator.so:${PORTSDIR}/www/eaccelerator
.elif ${PORT_OPTIONS:MXCACHE}
RUN_DEPENDS+= ${LOCALBASE}/lib/php/${PHP_EXT_DIR}/xcache.so:${PORTSDIR}/www/xcache
.endif
do-install:
@${MKDIR} ${PREFIX}/${MEDIAWIKIDIR}
${CP} -r ${WRKSRC}/ ${PREFIX}/${MEDIAWIKIDIR}
${CHOWN} -R ${WWWOWN}:${WWWGRP} ${PREFIX}/${MEDIAWIKIDIR}
post-install:
@${FIND} ${WRKSRC}/${file} -not -type d \
| ${SED} -ne 's,^${WRKSRC},${MEDIAWIKIDIR},p' >> ${TMPPLIST}
@${FIND} -d ${WRKSRC}/${file} -type d \
| ${SED} -ne 's,^${WRKSRC},@dirrm ${MEDIAWIKIDIR},p' >> ${TMPPLIST}
@${SED} -e 's|%%MEDIAWIKIDIR%%|${PREFIX}/${MEDIAWIKIDIR}|' ${PKGMESSAGE}
.include <bsd.port.mk>