blob: f2b87e83b4b847f89fa6a6fb9cdfd1ee64b5b1e6 (
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
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
|
# New ports collection makefile for: OpenTTD
# Date created: 16 Dec 2004
# Whom: Alexey Dokuchaev <danfe@FreeBSD.org>
#
# $FreeBSD$
#
PORTNAME= openttd
PORTVERSION= 0.7.5
PORTREVISION= 1
CATEGORIES= games
MASTER_SITES= http://gb.binaries.openttd.org/binaries/releases/${PORTVERSION}/ \
#SF/${PORTNAME}/${PORTNAME}/${PORTNAME}-${PORTVERSION}
MAINTAINER= danfe@FreeBSD.org
COMMENT= An open source clone of Microprose Transport Tycoon Deluxe
LIB_DEPENDS= png.6:${PORTSDIR}/graphics/png
HAS_CONFIGURE= yes
USE_BZIP2= yes
USE_GMAKE= yes
INSTALLS_ICONS= yes
MAKE_JOBS_SAFE= yes
CONFIGURE_ARGS= --prefix-dir="${PREFIX}" --data-dir="${DATADIR_REL}"
DISTVERSIONSUFFIX= -source
WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION}
.if defined(WITH_MIDI_PLAYER)
CONFIGURE_ARGS+= --with-midi=${WITH_MIDI_PLAYER}
.endif
.if defined(WITH_MIDI_PLAYER_ARGS)
CONFIGURE_ARGS+= --with-midi-arg=${WITH_MIDI_PLAYER_ARGS}
.endif
.if defined(WITH_DEDICATED_SERVER_ONLY)
CONFIGURE_ARGS+= --enable-dedicated
.else
LIB_DEPENDS+= freetype.9:${PORTSDIR}/print/freetype2 \
fontconfig.1:${PORTSDIR}/x11-fonts/fontconfig
USE_SDL= sdl
.endif
SUB_FILES= pkg-message
MAN6= openttd.6
DESKTOP_ENTRIES="OpenTTD" "${COMMENT}" "openttd" "openttd" \
"Game;Simulation;StrategyGame;" false
PORTDOCS= 32bpp.txt HOWTO_compile_lang_files.txt Manual.txt elrail.svg \
elrail_tile.png elrail_track.png landscape.html \
landscape_externals.html landscape_grid.html multiplayer.txt \
obg_format.txt ottd-colour-palette.gif \
ottd-colourtext-palette.png tileh.png
pre-everything::
.if !defined(WITH_MIDI_PLAYER)
@${ECHO_MSG} "Define WITH_MIDI_PLAYER=/path/to/player to build with external MIDI player"
.endif
.if !defined(WITH_MIDI_PLAYER_ARGS)
@${ECHO_MSG} "Define WITH_MIDI_PLAYER_ARGS=arguments for external MIDI player"
.endif
.if !defined(WITH_DEDICATED_SERVER_ONLY)
@${ECHO_MSG} "Define WITH_DEDICATED_SERVER_ONLY to build CLI-based dedicated server"
.endif
post-patch:
# Remove extra (vendor) CFLAGS, we set our own
@${REINPLACE_CMD} '1102,1103d' ${WRKSRC}/config.lib
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/bin/${PORTNAME} ${PREFIX}/bin
@${MKDIR} ${DATADIR}/data ${DATADIR}/lang ${DATADIR}/scripts
${INSTALL_DATA} ${WRKSRC}/bin/data/* ${DATADIR}/data
${INSTALL_DATA} ${WRKSRC}/bin/lang/* ${DATADIR}/lang
${INSTALL_DATA} ${WRKSRC}/bin/scripts/* ${DATADIR}/scripts
${INSTALL_MAN} ${WRKSRC}/docs/${MAN6} ${MANPREFIX}/man/man6
.for n in 16 32 48 64 128 256
@${MKDIR} ${PREFIX}/share/icons/hicolor/${n}x${n}/apps
${INSTALL_DATA} ${WRKSRC}/media/openttd.${n}.png \
${PREFIX}/share/icons/hicolor/${n}x${n}/apps/openttd.png
.endfor
.if !defined(NOPORTDOCS)
@${MKDIR} ${DOCSDIR}
${INSTALL_DATA} ${PORTDOCS:S,^,${WRKSRC}/docs/,} ${DOCSDIR}
.endif
post-install:
@${ECHO_MSG}
@${CAT} ${PKGMESSAGE}
@${ECHO_MSG}
.include <bsd.port.mk>
|