2003-01-21 02:02:48 +00:00
|
|
|
# New ports collection makefile for: cube
|
|
|
|
# Date created: 17 October 2002
|
|
|
|
# Whom: Arjan van Leeuwen
|
|
|
|
#
|
|
|
|
# $FreeBSD$
|
|
|
|
#
|
|
|
|
|
|
|
|
PORTNAME= cube
|
2006-08-07 02:30:38 +00:00
|
|
|
PORTVERSION= 2005.08.29
|
2012-06-01 05:26:28 +00:00
|
|
|
PORTREVISION= 11
|
2003-01-21 02:02:48 +00:00
|
|
|
CATEGORIES= games
|
2009-08-22 00:23:13 +00:00
|
|
|
MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/2005_08_29
|
2006-08-07 02:30:38 +00:00
|
|
|
DISTFILES= ${CUBE_DATA} ${CUBE_SRC}
|
|
|
|
EXTRACT_ONLY= ${CUBE_SRC}
|
2003-01-21 02:02:48 +00:00
|
|
|
|
2006-09-04 06:23:06 +00:00
|
|
|
MAINTAINER= ports@FreeBSD.org
|
2003-02-21 12:06:51 +00:00
|
|
|
COMMENT= An OpenGL 3D First Person Shooter game
|
2003-01-21 02:02:48 +00:00
|
|
|
|
2006-09-24 12:31:43 +00:00
|
|
|
BUILD_DEPENDS= ${LOCALBASE}/lib/libenet.a:${PORTSDIR}/net/enet
|
2006-09-17 01:38:17 +00:00
|
|
|
|
2006-08-07 02:30:38 +00:00
|
|
|
USE_ZIP= yes
|
|
|
|
USE_DOS2UNIX= yes
|
2003-01-21 02:02:48 +00:00
|
|
|
USE_GMAKE= yes
|
2006-08-07 02:30:38 +00:00
|
|
|
WRKSRC= ${WRKDIR}/${PORTNAME}_source/src
|
2006-09-24 12:31:43 +00:00
|
|
|
CFLAGS+= -fsigned-char
|
|
|
|
ALL_TARGET= #empty
|
2009-12-18 02:44:30 +00:00
|
|
|
MALE_JOBS_SAFE= yes
|
2003-01-21 02:02:48 +00:00
|
|
|
|
2012-06-12 16:35:45 +00:00
|
|
|
OPTIONS_DEFINE= OPTIMIZED_CFLAGS DOCS
|
|
|
|
OPTIONS_MULTI= TYPE
|
|
|
|
OPTIONS_MULTI_TYPE= CLIENT DEDICATED
|
|
|
|
OPTIONS_DEFAULT= CLIENT DEDICATED
|
|
|
|
CLIENT_DESC= Build client
|
|
|
|
DEDICATED_DESC= Build dedicated server
|
2003-01-21 02:02:48 +00:00
|
|
|
|
2005-10-06 10:15:36 +00:00
|
|
|
SUB_FILES= cube_client cube_server
|
|
|
|
|
2006-08-07 02:30:38 +00:00
|
|
|
CUBE_DATA= ${PORTNAME}_${PORTVERSION:S/./_/g}_unix.tar.gz
|
|
|
|
CUBE_SRC= ${PORTNAME}_${PORTVERSION:S/./_/g}_src.zip
|
|
|
|
|
2012-06-12 16:35:45 +00:00
|
|
|
.include <bsd.port.options.mk>
|
2006-08-07 02:30:38 +00:00
|
|
|
|
2012-06-12 16:35:45 +00:00
|
|
|
.if ${PORT_OPTIONS:MCLIENT}
|
2006-08-07 02:30:38 +00:00
|
|
|
USE_GL= yes
|
|
|
|
USE_SDL= image mixer sdl
|
2006-08-08 16:43:24 +00:00
|
|
|
ALL_TARGET+= client
|
2006-08-07 02:30:38 +00:00
|
|
|
PLIST_SUB+= CLIENT=""
|
|
|
|
CUBE_BIN+= client
|
|
|
|
.else
|
2006-09-24 12:31:43 +00:00
|
|
|
PLIST_SUB+= CLIENT="@comment "
|
2006-08-07 02:30:38 +00:00
|
|
|
.endif
|
|
|
|
|
2012-06-12 16:35:45 +00:00
|
|
|
.if ${PORT_OPTIONS:MDEDICATED}
|
2006-08-08 16:43:24 +00:00
|
|
|
ALL_TARGET+= server
|
2006-08-07 02:30:38 +00:00
|
|
|
PLIST_SUB+= DEDICATED=""
|
|
|
|
CUBE_BIN+= server
|
|
|
|
.else
|
2006-09-24 12:31:43 +00:00
|
|
|
PLIST_SUB+= DEDICATED="@comment "
|
|
|
|
.endif
|
|
|
|
|
2012-06-12 16:35:45 +00:00
|
|
|
.if ${PORT_OPTIONS:MOPTIMIZED_CFLAGS}
|
2006-09-24 12:31:43 +00:00
|
|
|
CFLAGS+= -O3 -fomit-frame-pointer
|
2006-08-07 02:30:38 +00:00
|
|
|
.endif
|
|
|
|
|
|
|
|
post-extract:
|
|
|
|
@${TAR} zxf ${DISTDIR}/${CUBE_DATA} -C ${WRKDIR}
|
2004-06-04 16:34:18 +00:00
|
|
|
|
2003-01-21 02:02:48 +00:00
|
|
|
do-install:
|
2006-08-07 02:30:38 +00:00
|
|
|
.for f in ${CUBE_BIN}
|
|
|
|
${INSTALL_SCRIPT} ${WRKDIR}/cube_${f} ${PREFIX}/bin
|
|
|
|
${INSTALL_PROGRAM} ${WRKSRC}/cube_${f} ${PREFIX}/libexec
|
|
|
|
.endfor
|
|
|
|
${MKDIR} ${DATADIR}
|
2006-09-24 12:31:43 +00:00
|
|
|
@(cd ${WRKDIR}/cube && ${COPYTREE_SHARE} "data packages" ${DATADIR}/)
|
2006-08-07 02:30:38 +00:00
|
|
|
${INSTALL_DATA} ${WRKDIR}/cube/autoexec.cfg ${DATADIR}
|
2012-06-12 16:35:45 +00:00
|
|
|
.if ${PORT_OPTIONS:MDOCS}
|
2006-08-07 02:30:38 +00:00
|
|
|
${MKDIR} ${DOCSDIR}
|
|
|
|
${INSTALL_DATA} ${WRKDIR}/cube/readme.html ${DOCSDIR}
|
2006-09-24 12:31:43 +00:00
|
|
|
@(cd ${WRKDIR}/cube/docs && ${COPYTREE_SHARE} \* ${DOCSDIR}/)
|
2006-08-07 02:30:38 +00:00
|
|
|
.endif
|
|
|
|
|
2012-06-12 16:35:45 +00:00
|
|
|
.include <bsd.port.mk>
|