2006-06-25 23:09:35 +00:00
|
|
|
# New ports collection makefile for: planeshift
|
|
|
|
# Date created: 2006-03-17
|
|
|
|
# Whom: Jose Alonso Cardenas Marquez <acardenas@bsd.org.pe>
|
|
|
|
#
|
|
|
|
# $FreeBSD$
|
|
|
|
#
|
|
|
|
|
|
|
|
PORTNAME= planeshift
|
2006-11-30 20:25:32 +00:00
|
|
|
PORTVERSION= 0.3.017
|
2007-05-19 20:36:56 +00:00
|
|
|
PORTREVISION= 2
|
2006-06-25 23:09:35 +00:00
|
|
|
CATEGORIES= games
|
2006-08-21 02:51:10 +00:00
|
|
|
MASTER_SITES= http://alex.foxybanana.com/freebsd/
|
2006-06-25 23:09:35 +00:00
|
|
|
|
2006-07-23 02:45:24 +00:00
|
|
|
MAINTAINER= acm@FreeBSD.org
|
2006-06-25 23:09:35 +00:00
|
|
|
COMMENT= First 3D MMORPG to be free for players
|
|
|
|
|
|
|
|
BUILD_DEPENDS= jam:${PORTSDIR}/devel/jam \
|
2006-08-21 02:51:10 +00:00
|
|
|
cs-config:${PORTSDIR}/graphics/crystalspace-devel \
|
|
|
|
cel-config:${PORTSDIR}/graphics/crystalentitylayer-devel \
|
2006-06-25 23:09:35 +00:00
|
|
|
${LOCALBASE}/lib/libbfd.a:${PORTSDIR}/devel/libbfd
|
2006-08-21 02:51:10 +00:00
|
|
|
LIB_DEPENDS= cal3d.12:${PORTSDIR}/graphics/cal3d \
|
2006-12-13 12:41:35 +00:00
|
|
|
curl.4:${PORTSDIR}/ftp/curl
|
2006-06-25 23:09:35 +00:00
|
|
|
|
|
|
|
USE_BZIP2= yes
|
|
|
|
GNU_CONFIGURE= yes
|
|
|
|
USE_AUTOTOOLS= automake:15:env autoconf:259:env
|
|
|
|
|
|
|
|
CPPFLAGS+= -I${LOCALBASE}/include -I${X11BASE}/include ${PTHREAD_LIBS}
|
|
|
|
LDFLAGS+= -L${LOCALBASE}/lib -L${X11BASE}/lib
|
|
|
|
CRYSTAL= ${LOCALBASE}
|
|
|
|
CEL= ${LOCALBASE}
|
|
|
|
CONFIGURE_TARGET= --build=${MACHINE_ARCH}-portbld-freebsd${OSREL}
|
|
|
|
CONFIGURE_ARGS= --enable-cpu-specific-optimizations=no
|
|
|
|
CONFIGURE_ENV= CPPFLAGS="${CPPFLAGS}" LDFLAGS="${LDFLAGS}" CRYSTAL="${CRYSTAL}" CEL="${CEL}"
|
|
|
|
SUB_FILES= pkg-message planeshift pssetup updater psserver
|
|
|
|
PLANEDIR= lib/${PORTNAME}
|
|
|
|
PLIST_SUB= PLANEDIR=${PLANEDIR}
|
2006-08-21 02:51:10 +00:00
|
|
|
INSTALL_PSDATA= ${INSTALL} ${COPY} ${_SHROWNGRP} -m 0644
|
2006-06-25 23:09:35 +00:00
|
|
|
|
|
|
|
JAM_CMD= jam
|
2006-08-21 02:51:10 +00:00
|
|
|
JAM_ARGS= -qa
|
2006-06-25 23:09:35 +00:00
|
|
|
|
|
|
|
OPTIONS= MYSQL "MySQL support for server mode " off
|
|
|
|
|
|
|
|
.include <bsd.port.pre.mk>
|
|
|
|
|
|
|
|
.if defined(WITH_MYSQL)
|
|
|
|
CONFIGURE_ARGS+= --with-mysqlclient
|
|
|
|
USE_MYSQL= yes
|
|
|
|
LIB_DEPENDS+= WN.2:${PORTSDIR}/textproc/wordnet
|
|
|
|
PLIST_SUB+= MYSQL="" \
|
|
|
|
EXAMPLE=""
|
|
|
|
MYSQL_FLAG= true
|
|
|
|
.else
|
|
|
|
CONFIGURE_ARGS+= --with-mysqlclient=no
|
|
|
|
PLIST_SUB+= MYSQL="@comment " \
|
|
|
|
EXAMPLE="@comment "
|
|
|
|
.endif
|
|
|
|
|
|
|
|
post-patch:
|
|
|
|
${REINPLACE_CMD} -e 's|%%AUTOHEADER%%|${AUTOHEADER}|g' -e 's|%%AUTOCONF%%|${AUTOCONF}|g' \
|
|
|
|
${WRKSRC}/autogen.sh
|
|
|
|
@cd ${WRKSRC}/src && \
|
|
|
|
${FIND} * -type f -name "*.c" -exec \
|
|
|
|
${REINPLACE_CMD} -i "" -e 's|malloc.h|stdlib.h|g' "{}" \;
|
2006-08-21 02:51:10 +00:00
|
|
|
@cd ${WRKSRC} && \
|
|
|
|
${FIND} * -type f -name ".cvsignore" -print0 | \
|
|
|
|
${XARGS} -0 ${RM} -R
|
2006-06-25 23:09:35 +00:00
|
|
|
|
|
|
|
pre-configure:
|
|
|
|
@cd ${WRKSRC} && ${SH} autogen.sh
|
|
|
|
|
|
|
|
do-build:
|
|
|
|
@cd ${WRKSRC} && \
|
2006-08-21 02:51:10 +00:00
|
|
|
${SETENV} ${MAKE_ENV} ${JAM_CMD} ${JAM_ARGS}
|
2006-06-25 23:09:35 +00:00
|
|
|
|
|
|
|
post-build:
|
|
|
|
@${REINPLACE_CMD} -e 's|<mirror id="1" name="local" url="http://192.168.2.19/updater/" />| \
|
|
|
|
<mirror id="1" name="mir1" url="http://psmirror.pfdev.net/psupdater/" \
|
2006-08-21 02:51:10 +00:00
|
|
|
repository="repository.zip" files="" /> \n \
|
2006-06-25 23:09:35 +00:00
|
|
|
<mirror id="2" name="mir2" url="http://planeshift.mirror.thumbnail.cz/psupdater/" \
|
2006-08-21 02:51:10 +00:00
|
|
|
repository="repository.zip" files="" /> \n \
|
2006-06-25 23:09:35 +00:00
|
|
|
<mirror id="3" name="mir3" url="http://www.psmirror.org/psupdater/" \
|
2006-08-21 02:51:10 +00:00
|
|
|
repository="repository.zip" files="" /> \n \
|
2006-06-25 23:09:35 +00:00
|
|
|
<mirror id="4" name="mir4" url="http://psmirror.u24.solone.net/psupdater/" \
|
2006-08-21 02:51:10 +00:00
|
|
|
repository="repository.zip" files="" /> \n \
|
2006-06-25 23:09:35 +00:00
|
|
|
<mirror id="5" name="backp" url="http://laanx.fragnetics.com/updater_hidden/" \
|
|
|
|
repository="repository.zip" files="" />|g' ${WRKSRC}/updaterconfig.xml
|
|
|
|
|
|
|
|
@${REINPLACE_CMD} -e 's|<module>docs</module>|<!-- <module>docs</module> -->|g' -e \
|
|
|
|
's|<module>root</module>|<!-- <module>root</module> -->|g' ${WRKSRC}/updaterconfig.xml
|
|
|
|
do-install:
|
|
|
|
@${MKDIR} ${PREFIX}/${PLANEDIR}
|
|
|
|
.for FILE in ase_2_spr eedit paws_generic pawseditor psclient psnpcclient psserver pssetup texparse updater
|
|
|
|
${INSTALL_PROGRAM} ${WRKSRC}/${FILE} ${PREFIX}/${PLANEDIR}
|
|
|
|
.endfor
|
|
|
|
|
|
|
|
.for FILE in *.cfg *.xml
|
2006-08-21 02:51:10 +00:00
|
|
|
${INSTALL_PSDATA} ${WRKSRC}/${FILE} ${PREFIX}/${PLANEDIR}
|
2006-06-25 23:09:35 +00:00
|
|
|
.endfor
|
|
|
|
|
|
|
|
.for DIRE in art data
|
|
|
|
@${MKDIR} ${PREFIX}/${PLANEDIR}/${DIRE}
|
|
|
|
@cd ${WRKSRC}/${DIRE} && \
|
|
|
|
${FIND} * -type d -exec ${MKDIR} "${PREFIX}/${PLANEDIR}/${DIRE}/{}" \; && \
|
2006-08-21 02:51:10 +00:00
|
|
|
${FIND} * -type f -exec ${INSTALL_PSDATA} "{}" "${PREFIX}/${PLANEDIR}/${DIRE}/{}" \;
|
2006-06-25 23:09:35 +00:00
|
|
|
.endfor
|
|
|
|
|
|
|
|
.if defined(MYSQL_FLAG)
|
|
|
|
${INSTALL_SCRIPT} ${WRKDIR}/psserver ${PREFIX}/bin
|
|
|
|
${INSTALL_PROGRAM} ${WRKSRC}/dbmysql.so ${PREFIX}/${PLANEDIR}
|
|
|
|
@${MKDIR} ${EXAMPLESDIR}
|
|
|
|
@cd ${WRKSRC}/src/server/database/mysql && \
|
|
|
|
${FIND} * -name "*.sql" -exec ${INSTALL_DATA} "{}" "${EXAMPLESDIR}/{}" \;
|
|
|
|
.endif
|
|
|
|
|
|
|
|
@${INSTALL_SCRIPT} ${WRKDIR}/planeshift ${WRKDIR}/updater ${WRKDIR}/pssetup ${PREFIX}/bin
|
|
|
|
|
|
|
|
post-install:
|
|
|
|
@${CAT} ${PKGMESSAGE}
|
|
|
|
|
|
|
|
.include <bsd.port.post.mk>
|