aboutsummaryrefslogtreecommitdiffstats
path: root/games/xbattle/Makefile
blob: 47c4eaed9a0a68a556a98dd101b1223f6824a949 (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
57
# Created by: Pedro Giffuni
# $FreeBSD$

PORTNAME=   xbattle
PORTVERSION=    5.4.1
PORTREVISION=   3
CATEGORIES= games
MASTER_SITES=   GENTOO/distfiles \
        SF/nemysisfreebsdp/${CATEGORIES}/${PORTNAME}/:icons
DISTFILES=  ${PORTNAME}-${DISTVERSION}${EXTRACT_SUFX} \
        ${PORTNAME}_icons${EXTRACT_SUFX}:icons

MAINTAINER= nemysis@FreeBSD.org
COMMENT=    Concurrent multi-player battle strategy game

RUN_DEPENDS=    xdialog>0:${PORTSDIR}/x11/xdialog

USES=       imake
USE_XORG=   x11 xext
USE_CSTD=   gnu89
CFLAGS+=    -Wno-return-type

PORTDOCS=   README
OPTIONS_DEFINE= DOCS

INSTALLS_ICONS= yes
ICON_SIZES= 32x32 48x48 64x64 72x72 96x96 128x128

SUB_FILES=  ${PORTNAME}-menu

DESKTOP_ENTRIES="XBattle" "" "${PORTNAME}" \
        "${PORTNAME}-menu" "Game;ArcadeGame;" ""

post-install:
    ${INSTALL_SCRIPT} ${WRKDIR}/${PORTNAME}-menu ${STAGEDIR}${PREFIX}/bin/
.for d in xbas xbos xbts
    @(cd ${WRKSRC} && ${COPYTREE_SHARE} ${d} ${STAGEDIR}${DATADIR})
    @${CHMOD} 755 ${STAGEDIR}${DATADIR}/${d}
    @${CHMOD} 644 ${STAGEDIR}${DATADIR}/${d}/*
.endfor
    @${CHMOD} 755 ${STAGEDIR}${DATADIR}
.for f in tutorial1 tutorial2
    ${INSTALL_SCRIPT} ${WRKSRC}/${f} ${STAGEDIR}${PREFIX}/bin/${PORTNAME}-${f}
.endfor

.for s in ${ICON_SIZES}
    @${MKDIR} ${STAGEDIR}${PREFIX}/share/icons/hicolor/${s}/apps/
    ${INSTALL_DATA} ${WRKDIR}/${PORTNAME}_${s}.png \
        ${STAGEDIR}${PREFIX}/share/icons/hicolor/${s}/apps/${PORTNAME}.png
.endfor
    ${LN} -sf ${PREFIX}/share/icons/hicolor/48x48/apps/${PORTNAME}.png \
        ${STAGEDIR}${PREFIX}/share/pixmaps/

    @${MKDIR} ${STAGEDIR}${DOCSDIR}
    ${INSTALL_DATA} ${PORTDOCS:S|^|${WRKSRC}/|} ${STAGEDIR}${DOCSDIR}

.include <bsd.port.mk>