aboutsummaryrefslogtreecommitdiffstats
path: root/games/linux-defcon/Makefile
blob: 12e64f90eb1c9f21b853f76afadadf22b9f5d9b4 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
# New ports collection makefile for:    linux-defcon
# Date created:             24 May 2007
# Whom:                 Marcus von Appen <mva@sysfault.org
#
# $FreeBSD$
#

PORTNAME=   defcon
PORTVERSION=    1.42
CATEGORIES= games linux
MASTER_SITES=   http://download.introversion.co.uk/defcon/linux/
PKGNAMEPREFIX=  linux-
DISTNAME=   ${PORTNAME}-v${PORTVERSION}

MAINTAINER= mva@FreeBSD.org
COMMENT=    Defcon for Linux

ONLY_FOR_ARCHS= i386 amd64
USE_LINUX=  yes
USE_LINUX_APPS= sdl12 libogg libvorbis xorglibs
NO_CDROM=   Redistribution is limited, see license
NO_BUILD=   yes

DATADIR=    ${PREFIX}/lib/${PKGNAMEPREFIX}${PORTNAME}
SUB_FILES=  defcon

OPTIONS=    NVIDIA  "Install support for nvidia"    off

.include <bsd.port.pre.mk>

.if defined(WITH_NVIDIA)
RUN_DEPENDS+=   ${LINUXBASE}/usr/lib/libGL.so.1:${PORTSDIR}/x11/nvidia-driver
USE_LINUX_APPS+=libglu
.else
USE_LINUX_APPS+=dri
.endif

do-build:
    ${BRANDELF} -t Linux ${WRKSRC}/lib/defcon.bin.x86

do-install:
    ${MKDIR} ${DATADIR}
    @cd ${WRKSRC}/lib && \
        ${INSTALL_PROGRAM} defcon.bin.x86 ${DATADIR} && \
        ${INSTALL_DATA} *.dat open-www.sh ${DATADIR}
    ${INSTALL_PROGRAM} ${WRKDIR}/defcon ${PREFIX}/bin/${PKGNAMEPREFIX}defcon
.if !defined (NOPORTDOCS)
    ${MKDIR} ${DOCSDIR}
    ${INSTALL_DATA} ${WRKSRC}/license.txt ${DOCSDIR}/license.txt
    ${INSTALL_DATA} ${WRKSRC}/manual.pdf ${DOCSDIR}/manual.pdf
.endif

post-install:
    @${CAT} ${PKGMESSAGE}

.include <bsd.port.post.mk>