summaryrefslogtreecommitdiff
path: root/games/crossfire-server/Makefile
blob: 50975402b1459839fec9f0cee3bce40d491b3811 (plain)
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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
# $NetBSD: Makefile,v 1.18 2012/10/03 21:56:04 wiz Exp $

DISTNAME=	crossfire-1.11.0
PKGNAME=	crossfire-server-1.11.0
PKGREVISION=	11
CATEGORIES=	games x11
MASTER_SITES=	${MASTER_SITE_SOURCEFORGE:=crossfire/}
DISTFILES=	${DISTNAME}${EXTRACT_SUFX}
DISTFILES+=	${DISTNAME}.arch.tar.gz ${DISTNAME}.maps.tar.bz2

MAINTAINER=	adam@NetBSD.org
HOMEPAGE=	http://crossfire.real-time.com/
COMMENT=	X11 multi/single player game similar to gauntlet and nethack

PKG_DESTDIR_SUPPORT=	user-destdir
PKG_SYSCONFSUBDIR=	crossfire

USE_LIBTOOL=		yes
USE_TOOLS+=		gmake perl:run bash:run csh:run
GNU_CONFIGURE=		yes
CONFIGURE_ARGS+=	--localstatedir=${VARBASE}/games
CONFIGURE_ARGS+=	--sysconfdir=${PKG_SYSCONFDIR}
CONFIGURE_ENV+=		ac_cv_path_GZIP=${GZIP_CMD:Q}
PLIST_SRC=		${WRKDIR}/PLIST PLIST

INSTALLATION_DIRS=	share/crossfire/arch
INSTALLATION_DIRS+=	share/crossfire/maps

# crossfire
REPLACE_BASH+=	utils/crossloop.web.in
REPLACE_PERL+=	doc/include_html.pl
REPLACE_PERL+=	doc/playbook/make_index.pl
REPLACE_PERL+=	doc/scripts/items-extract.pl
REPLACE_PERL+=	doc/scripts/makeps.pl
REPLACE_PERL+=	doc/scripts/monster-extract.pl
REPLACE_PERL+=	lib/adm/archsearch.pl
REPLACE_PERL+=	lib/adm/collect_images.pl
REPLACE_PERL+=	lib/adm/map_expand.pl
REPLACE_PERL+=	lib/adm/mapslitter.pl
REPLACE_PERL+=	lib/checkarch.pl
REPLACE_PERL+=	lib/collect.pl
REPLACE_PERL+=	lib/util.pl
REPLACE_PERL+=	utils/metaserver.pl
REPLACE_PERL+=	utils/player_dl.pl.in
REPLACE_PERL+=	utils/metaserver.pl.in
REPLACE_PERL+=	utils/mktable.script
REPLACE_PERL+=	lib/adm/map_info
# arch
REPLACE_CSH+=	../arch/dev/xpmtopng
REPLACE_CSH+=	../arch/dev/merge.csh
REPLACE_CSH+=	../arch/dev/scripts/updatearch
REPLACE_PERL+=	../arch/dev/scripts/update_armor.pl
REPLACE_PERL+=	../arch/dev/scripts/update_body.pl
REPLACE_PERL+=	../arch/dev/scripts/update_monster.pl
REPLACE_PERL+=	../arch/dev/scripts/update_object.pl
REPLACE_PERL+=	../arch/dev/scripts/update_shield.pl
REPLACE_PERL+=	../arch/dev/split-png-linux.pl
REPLACE_PERL+=	../arch/dev/splitter-png.pl
REPLACE_PERL+=	../arch/dev/splitter.pl
# maps
REPLACE_BASH+=	../maps/brest/pshops/pshop_copier
REPLACE_PERL+=	../maps/Info/combine.pl
REPLACE_PERL+=	../maps/Info/map_sed.pl
REPLACE_PERL+=	../maps/Info/rewrite_exits.pl
REPLACE_PERL+=	../maps/Info/rewrite_styles.pl
REPLACE_PERL+=	../maps/Info/update_apart.pl
REPLACE_PERL+=	../maps/Info/update_exits.pl

EGDIR=		${PREFIX}/share/examples/crossfire
CONF_FILES+=	${EGDIR}/ban_file ${PKG_SYSCONFDIR}/ban_file
CONF_FILES+=	${EGDIR}/dm_file ${PKG_SYSCONFDIR}/dm_file
CONF_FILES+=	${EGDIR}/exp_table ${PKG_SYSCONFDIR}/exp_table
CONF_FILES+=	${EGDIR}/forbid ${PKG_SYSCONFDIR}/forbid
CONF_FILES+=	${EGDIR}/metaserver2 ${PKG_SYSCONFDIR}/metaserver2
CONF_FILES+=	${EGDIR}/motd ${PKG_SYSCONFDIR}/motd
CONF_FILES+=	${EGDIR}/news ${PKG_SYSCONFDIR}/news
CONF_FILES+=	${EGDIR}/rules ${PKG_SYSCONFDIR}/rules
CONF_FILES+=	${EGDIR}/settings ${PKG_SYSCONFDIR}/settings

post-install:
	cd ${WRKDIR} && cp -R arch maps ${DESTDIR}${PREFIX}/share/crossfire
	cd ${DESTDIR}${PREFIX} && \
		${FIND} share/crossfire/arch -type f -print >> ${WRKDIR}/PLIST
	cd ${DESTDIR}${PREFIX} && \
		${FIND} share/crossfire/maps -type f -print >> ${WRKDIR}/PLIST

.include "options.mk"

.include "../../graphics/png/buildlink3.mk"
.include "../../textproc/libxslt/buildlink3.mk"
.include "../../www/curl/buildlink3.mk"

.include "../../lang/python/application.mk"
.include "../../mk/bsd.pkg.mk"