aboutsummaryrefslogtreecommitdiffstats
path: root/games/4stattack/Makefile
blob: 200b1b93b659e2f7ee09c4b8db0751fa5a1fb073 (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
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
# New ports collection makefile for:    4stAttack
# Date created:         26 Jan 2004
# Whom:             Jean-Yves Lefort <jylefort@brutele.be>
#
# $FreeBSD$
#

PORTNAME=   4stattack
PORTVERSION=    2.1.4
PORTREVISION=   2
CATEGORIES= games
MASTER_SITES=   ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= forcedattack
DISTNAME=   4stAttack-${PORTVERSION}

MAINTAINER= jylefort@FreeBSD.org
COMMENT=    Connect four stones in a straight line

RUN_DEPENDS=    ${PYTHON_SITELIBDIR}/pygame/__init__.py:${PORTSDIR}/devel/py-game

USE_PYTHON= yes
USE_X_PREFIX=   yes
USE_REINPLACE=  yes
NO_BUILD=   yes

PYC=        PYTHON="${PYTHON_CMD}" ${SH} ${SCRIPTDIR}/py-compile

post-patch:
    @${REINPLACE_CMD} -e 's|%%DATADIR%%|${DATADIR}|; s|%%PYTHON%%|${PYTHON_CMD}|' \
        ${WRKSRC}/4stattack

do-install:
    ${MKDIR} ${PREFIX}/bin
    ${INSTALL_SCRIPT} \
        ${WRKSRC}/4stattack \
        ${PREFIX}/bin

    ${MKDIR} ${DATADIR}
    ${INSTALL_DATA} \
        ${WRKSRC}/4stattack.py \
        ${WRKSRC}/animator.py \
        ${WRKSRC}/board.py \
        ${WRKSRC}/chat.py \
        ${WRKSRC}/creditsscreen.py \
        ${WRKSRC}/endgamedialog.py \
        ${WRKSRC}/endscreen.py \
        ${WRKSRC}/game.py \
        ${WRKSRC}/gamelog.py \
        ${WRKSRC}/gamescreen.py \
        ${WRKSRC}/inisettings.py \
        ${WRKSRC}/multiplayerscreen.py \
        ${WRKSRC}/quit.py \
        ${WRKSRC}/rules.py \
        ${WRKSRC}/scoremap.py \
        ${WRKSRC}/setini.py \
        ${WRKSRC}/settings.ini \
        ${WRKSRC}/settingsscreen.py \
        ${WRKSRC}/startscreen.py \
        ${WRKSRC}/technical.ttf \
        ${WRKSRC}/testgui.py \
        ${WRKSRC}/testini.py \
        ${WRKSRC}/themeresizer.py \
        ${WRKSRC}/themeresizer.sh \
        ${WRKSRC}/version \
        ${DATADIR}
    ${PYC} --basedir ${DATADIR} \
        ${DATADIR}/4stattack.py \
        ${DATADIR}/animator.py \
        ${DATADIR}/board.py \
        ${DATADIR}/chat.py \
        ${DATADIR}/creditsscreen.py \
        ${DATADIR}/endgamedialog.py \
        ${DATADIR}/endscreen.py \
        ${DATADIR}/game.py \
        ${DATADIR}/gamelog.py \
        ${DATADIR}/gamescreen.py \
        ${DATADIR}/inisettings.py \
        ${DATADIR}/multiplayerscreen.py \
        ${DATADIR}/quit.py \
        ${DATADIR}/rules.py \
        ${DATADIR}/scoremap.py \
        ${DATADIR}/setini.py \
        ${DATADIR}/settingsscreen.py \
        ${DATADIR}/startscreen.py \
        ${DATADIR}/testgui.py \
        ${DATADIR}/testini.py \
        ${DATADIR}/themeresizer.py

    ${MKDIR} ${DATADIR}/data/music
    ${INSTALL_DATA} \
        ${WRKSRC}/data/music/4stattack.ogg \
        ${DATADIR}/data/music

    ${MKDIR} ${DATADIR}/data/themes/clean
    ${INSTALL_DATA} \
        ${WRKSRC}/data/themes/clean/audio.ini \
        ${WRKSRC}/data/themes/clean/graphics.ini \
        ${DATADIR}/data/themes/clean

    ${MKDIR} ${DATADIR}/data/themes/clean/1024x768
    ${INSTALL_DATA} \
        ${WRKSRC}/data/themes/clean/1024x768/awaitingconnection.png \
        ${WRKSRC}/data/themes/clean/1024x768/back.png \
        ${WRKSRC}/data/themes/clean/1024x768/background.png \
        ${WRKSRC}/data/themes/clean/1024x768/chakie.png \
        ${WRKSRC}/data/themes/clean/1024x768/connecting-plain.png \
        ${WRKSRC}/data/themes/clean/1024x768/connecting.png \
        ${WRKSRC}/data/themes/clean/1024x768/credits.png \
        ${WRKSRC}/data/themes/clean/1024x768/cursor.png \
        ${WRKSRC}/data/themes/clean/1024x768/draw.png \
        ${WRKSRC}/data/themes/clean/1024x768/error-connecting.png \
        ${WRKSRC}/data/themes/clean/1024x768/frame.png \
        ${WRKSRC}/data/themes/clean/1024x768/frm_bl.png \
        ${WRKSRC}/data/themes/clean/1024x768/frm_br.png \
        ${WRKSRC}/data/themes/clean/1024x768/frm_left.png \
        ${WRKSRC}/data/themes/clean/1024x768/frm_right.png \
        ${WRKSRC}/data/themes/clean/1024x768/frm_tl.png \
        ${WRKSRC}/data/themes/clean/1024x768/frm_top.png \
        ${WRKSRC}/data/themes/clean/1024x768/frm_tr.png \
        ${WRKSRC}/data/themes/clean/1024x768/fullscreen.png \
        ${WRKSRC}/data/themes/clean/1024x768/graphics.png \
        ${WRKSRC}/data/themes/clean/1024x768/green-zebra.png \
        ${WRKSRC}/data/themes/clean/1024x768/grid.png \
        ${WRKSRC}/data/themes/clean/1024x768/hostagame.png \
        ${WRKSRC}/data/themes/clean/1024x768/joinagame.png \
        ${WRKSRC}/data/themes/clean/1024x768/keepplaying.png \
        ${WRKSRC}/data/themes/clean/1024x768/korruptor.png \
        ${WRKSRC}/data/themes/clean/1024x768/locations.ini \
        ${WRKSRC}/data/themes/clean/1024x768/logo.png \
        ${WRKSRC}/data/themes/clean/1024x768/multiplayer.png \
        ${WRKSRC}/data/themes/clean/1024x768/music.png \
        ${WRKSRC}/data/themes/clean/1024x768/ok.png \
        ${WRKSRC}/data/themes/clean/1024x768/playervscpu.png \
        ${WRKSRC}/data/themes/clean/1024x768/programming.png \
        ${WRKSRC}/data/themes/clean/1024x768/pygame.png \
        ${WRKSRC}/data/themes/clean/1024x768/quit.png \
        ${WRKSRC}/data/themes/clean/1024x768/quitgame.png \
        ${WRKSRC}/data/themes/clean/1024x768/radio-off.png \
        ${WRKSRC}/data/themes/clean/1024x768/radio-on.png \
        ${WRKSRC}/data/themes/clean/1024x768/radio.png \
        ${WRKSRC}/data/themes/clean/1024x768/selector.png \
        ${WRKSRC}/data/themes/clean/1024x768/selector1.png \
        ${WRKSRC}/data/themes/clean/1024x768/selector2.png \
        ${WRKSRC}/data/themes/clean/1024x768/settings.png \
        ${WRKSRC}/data/themes/clean/1024x768/slm-text.png \
        ${WRKSRC}/data/themes/clean/1024x768/slm.png \
        ${WRKSRC}/data/themes/clean/1024x768/start.png \
        ${WRKSRC}/data/themes/clean/1024x768/stone_1.png \
        ${WRKSRC}/data/themes/clean/1024x768/stone_2.png \
        ${WRKSRC}/data/themes/clean/1024x768/thanks.png \
        ${WRKSRC}/data/themes/clean/1024x768/wannaquit.png \
        ${WRKSRC}/data/themes/clean/1024x768/won_1.png \
        ${WRKSRC}/data/themes/clean/1024x768/won_2.png \
        ${DATADIR}/data/themes/clean/1024x768

    ${MKDIR} ${DATADIR}/gui
    ${INSTALL_DATA} \
        ${WRKSRC}/gui/__init__.py \
        ${WRKSRC}/gui/button.py \
        ${WRKSRC}/gui/canvas.py \
        ${WRKSRC}/gui/checkbox.py \
        ${WRKSRC}/gui/dialog.py \
        ${WRKSRC}/gui/editfield.py \
        ${WRKSRC}/gui/fader.py \
        ${WRKSRC}/gui/image.py \
        ${WRKSRC}/gui/label.py \
        ${WRKSRC}/gui/messagebox.py \
        ${WRKSRC}/gui/progress.py \
        ${WRKSRC}/gui/widget.py \
        ${WRKSRC}/gui/widget_manager.py \
        ${DATADIR}/gui
    ${PYC} --basedir ${DATADIR}/gui \
        ${DATADIR}/gui/__init__.py \
        ${DATADIR}/gui/button.py \
        ${DATADIR}/gui/canvas.py \
        ${DATADIR}/gui/checkbox.py \
        ${DATADIR}/gui/dialog.py \
        ${DATADIR}/gui/editfield.py \
        ${DATADIR}/gui/fader.py \
        ${DATADIR}/gui/image.py \
        ${DATADIR}/gui/label.py \
        ${DATADIR}/gui/messagebox.py \
        ${DATADIR}/gui/progress.py \
        ${DATADIR}/gui/widget.py \
        ${DATADIR}/gui/widget_manager.py

    ${MKDIR} ${DATADIR}/gui/dialogs
    ${INSTALL_DATA} \
        ${WRKSRC}/gui/dialogs/dialog \
        ${WRKSRC}/gui/dialogs/end_game.py \
        ${WRKSRC}/gui/dialogs/info_map.py \
        ${WRKSRC}/gui/dialogs/info_scenario.py \
        ${WRKSRC}/gui/dialogs/info_units.py \
        ${WRKSRC}/gui/dialogs/main_dialog.py \
        ${WRKSRC}/gui/dialogs/new_game.py \
        ${WRKSRC}/gui/dialogs/select_scenario.py \
        ${WRKSRC}/gui/dialogs/setup_client.py \
        ${WRKSRC}/gui/dialogs/setup_network.py \
        ${WRKSRC}/gui/dialogs/setup_players.py \
        ${WRKSRC}/gui/dialogs/start_game.py \
        ${WRKSRC}/gui/dialogs/wait_client.py \
        ${DATADIR}/gui/dialogs
    ${PYC} --basedir ${DATADIR}/gui/dialogs \
        ${DATADIR}/gui/dialogs/end_game.py \
        ${DATADIR}/gui/dialogs/info_map.py \
        ${DATADIR}/gui/dialogs/info_scenario.py \
        ${DATADIR}/gui/dialogs/info_units.py \
        ${DATADIR}/gui/dialogs/main_dialog.py \
        ${DATADIR}/gui/dialogs/new_game.py \
        ${DATADIR}/gui/dialogs/select_scenario.py \
        ${DATADIR}/gui/dialogs/setup_client.py \
        ${DATADIR}/gui/dialogs/setup_network.py \
        ${DATADIR}/gui/dialogs/setup_players.py \
        ${DATADIR}/gui/dialogs/start_game.py \
        ${DATADIR}/gui/dialogs/wait_client.py

    ${MKDIR} ${DATADIR}/players
    ${INSTALL_DATA} \
        ${WRKSRC}/players/__init__.py \
        ${WRKSRC}/players/agressive.py \
        ${WRKSRC}/players/connectscore.py \
        ${WRKSRC}/players/human.py \
        ${WRKSRC}/players/minmax.py \
        ${WRKSRC}/players/multiplayer.py \
        ${WRKSRC}/players/multiplayer_receiver.py \
        ${WRKSRC}/players/multiplayer_sender.py \
        ${WRKSRC}/players/neuralai.py \
        ${WRKSRC}/players/player.py \
        ${WRKSRC}/players/randomai.py \
        ${WRKSRC}/players/strategic.py \
        ${WRKSRC}/players/treeai.py \
        ${WRKSRC}/players/weighted.py \
        ${DATADIR}/players
    ${PYC} --basedir ${DATADIR}/players \
        ${DATADIR}/players/__init__.py \
        ${DATADIR}/players/agressive.py \
        ${DATADIR}/players/connectscore.py \
        ${DATADIR}/players/human.py \
        ${DATADIR}/players/minmax.py \
        ${DATADIR}/players/multiplayer.py \
        ${DATADIR}/players/multiplayer_receiver.py \
        ${DATADIR}/players/multiplayer_sender.py \
        ${DATADIR}/players/neuralai.py \
        ${DATADIR}/players/player.py \
        ${DATADIR}/players/randomai.py \
        ${DATADIR}/players/strategic.py \
        ${DATADIR}/players/treeai.py \
        ${DATADIR}/players/weighted.py

.if !defined(NOPORTDOCS)
    ${MKDIR} ${DOCSDIR}
    ${INSTALL_DATA} \
        ${WRKSRC}/changelog.txt \
        ${WRKSRC}/credits.txt \
        ${DOCSDIR}
.endif

.include <bsd.port.mk>