freebsd-ports/www/MT/Makefile
Tilman Keskinoz 850c24715a Upgrade to 3.2, since the old version is not available anymore.
Lots of changes since 2.661, e.g.
- the nofollow plugin is now included
- the configuration file has been renamed
- Support for Atom feeds
- a new Junk filter, comment and trackback moderation
2005-09-25 17:15:36 +00:00

122 lines
3.7 KiB
Makefile

# New ports collection makefile for: MT
# Date created: Fri Jun 13 16:39:20 CST 2003
# Whom: Foxfair Hu <foxfair@FreeBSD.org>
#
# $FreeBSD$
#
PORTNAME= MT
PORTVERSION= 3.2
CATEGORIES= www
MAINTAINER= arved@FreeBSD.org
COMMENT= A web-based personal publishing system for weblogs
RUN_DEPENDS= ${SITE_PERL}/HTML/Template.pm:${PORTSDIR}/www/p5-HTML-Template \
${SITE_PERL}/Image/Size.pm:${PORTSDIR}/graphics/p5-Image-Size \
${SITE_PERL}/CGI.pm:${PORTSDIR}/www/p5-CGI.pm
.if !defined(WITHOUT_OPTIONAL_MODULES)
RUN_DEPENDS+= ${SITE_PERL}/LWP/UserAgent.pm:${PORTSDIR}/www/p5-libwww \
${SITE_PERL}/SOAP/Lite.pm:${PORTSDIR}/net/p5-SOAP-Lite \
${SITE_PERL}/${PERL_ARCH}/Image/Magick.pm:${PORTSDIR}/graphics/ImageMagick
.endif
WRKSRC= ${WRKDIR}/MT-${PORTVERSION}-en_US
DATADIR= www/data
CGIDIR= www/cgi-bin/mt
.if defined(WITH_MYSQL)
DB_DIR?= /var/db/mysql/blog
USE_MYSQL= yes
.elif defined(WITH_POSTGRES)
DB_DIR?= ${PREFIX}/pgsql/data/blog
# Or somewhere defined in $PGDATA
USE_PGSQL= yes
.elif defined(WITH_SQLITE)
DB_DIR?= ${PREFIX}/${CGIDIR}/db
RUN_DEPENDS+=\
${SITE_PERL}/${PERL_ARCH}/DBD/SQLite.pm:${PORTSDIR}/databases/p5-DBD-SQLite
.else
DB_DIR?= ${PREFIX}/${CGIDIR}/db
WITH_DEFAULTDB= yes
.endif
PLIST_SUB+= DATADIR=${DATADIR} CGIDIR=${CGIDIR}
USE_PERL5_RUN= yes
NO_BUILD= yes
RESTRICTED= License does not permit distribution
.include <bsd.port.pre.mk>
.if !exists(${DISTDIR}/${DISTNAME}${EXTRACT_SUFX})
IGNORE= \
: Because of licensing restrictions, you must fetch the source distribution\
manually.\
Goto http://www.movabletype.org/ and download the "Personal Free Edition"\
Download the tar.gz file into ${DISTDIR}/, and then run make again
ECHO_MSG=${ECHO_CMD}
.endif
.if !defined(WITHOUT_OPTIONAL_MODULES)
.if ${PERL_LEVEL} < 500800
RUN_DEPENDS+= ${SITE_PERL}/File/Temp.pm:${PORTSDIR}/devel/p5-File-Temp
.endif
.endif
.if ${PERL_LEVEL} < 500601
RUN_DEPENDS+= ${SITE_PERL}/${PERL_ARCH}/File/Spec.pm:${PORTSDIR}/devel/p5-PathTools
.endif
pre-everything::
@${ECHO_CMD} "ATTENTION:"
@${ECHO_CMD} "If you are upgrading from an older version of MT"
@${ECHO_CMD} "please read http://www.sixapart.com/movabletype/docs/${PORTVERSION}/"
@${ECHO_CMD} "BEFORE installing this port"
@${ECHO_CMD} ""
@${ECHO_CMD} "Available switches:"
@${ECHO_CMD} "-------------------"
@${ECHO_CMD} "DB_DIR"
@${ECHO_CMD} " - Override the default database directory"
@${ECHO_CMD} " (${DB_DIR})"
.if !defined(WITHOUT_OPTIONAL_MODULES)
@${ECHO_CMD} "WITHOUT_OPTIONAL_MODULES"
@${ECHO_CMD} " - Don't install optional perl modules, needed for"
@${ECHO_CMD} " Trackbacks, XML-RPC and thumbnails"
.endif
.if !defined(WITH_MYSQL)
@${ECHO_CMD} "WITH_MYSQL"
@${ECHO_CMD} " - Use MySQL instead of Berkeley DB as database backend"
.endif
.if !defined(WITH_MYSQL)
@${ECHO_CMD} "WITH_POSTGRES"
@${ECHO_CMD} " - Use PostgreSQL instead of Berkeley DB as database backend"
.endif
.if !defined(WITH_SQLITE)
@${ECHO_CMD} "WITH_SQLITE"
@${ECHO_CMD} " - Use SQLite instead of Berkeley DB as database backend"
.endif
do-install:
@cd ${WRKSRC} && ${FIND} * -name "*.orig" -delete
@${ECHO_MSG} "Installing cgi under ${PREFIX}/${CGIDIR}/"
@${MKDIR} ${PREFIX}/${CGIDIR}
@cd ${WRKSRC} && ${CP} -R *.cgi mt-config.cgi-original \
extlib default_templates extlib extras import lib php plugins search_templates \
tmpl tools ${PREFIX}/${CGIDIR}
@${ECHO_MSG} "Installing data under ${PREFIX}/${DATADIR}/"
@${MKDIR} ${PREFIX}/${DATADIR}
@cd ${WRKSRC} && ${CP} -R mt-static \
${PREFIX}/${DATADIR}
.if defined(WITH_DEFAULTDB)
@${MKDIR} -m 755 ${DB_DIR}
@${CHOWN} -R www:www ${DB_DIR}
.endif
@${CHOWN} -R www:www ${PREFIX}/${CGIDIR} ${PREFIX}/${DATADIR}
post-install:
@${ECHO_CMD} ""
@${ECHO_MSG} "Please read the documentation http://www.sixapart.com/movabletype/docs/${PORTVERSION}/"
.include <bsd.port.post.mk>