]>
Commit | Line | Data |
---|---|---|
a2d6e64d | 1 | # |
7a1462a3 | 2 | # TODO: |
6308c089 SS |
3 | # - gtk3 client is broken: |
4 | # GTK+ 2.x symbols detected. Using GTK+ 2.x and GTK+ 3 in the same process is not supported | |
5 | # - work on authentication and Freeciv database support (fcdb) | |
05a36390 | 6 | # - patch all packaged desktop files |
21d7c5ed | 7 | # - get rid freeciv-stub (or not) |
24382cc8 | 8 | # |
a2d6e64d | 9 | # Conditional build: |
696a3e6e | 10 | %bcond_without ggz_client # build without ggz client |
11 | %bcond_without ggz_server # build without ggz server | |
1304e7cf | 12 | %bcond_without magickwand # build without MagickWand map image toolkit support |
852f1cf3 | 13 | %bcond_without system_lua # build with bundled lua |
73fd6aa7 SS |
14 | %bcond_without gtk2 # build without gtk2 client |
15 | %bcond_without gtk3 # build without gtk3 client | |
16 | %bcond_without sdl # build without sdl client | |
17 | %bcond_without xaw # build without xaw client | |
18 | %bcond_with qt # build with qt client (broken) | |
e748604f | 19 | # |
68badbcf | 20 | Summary: FREE CIVilization clone |
a2d6e64d | 21 | Summary(es.UTF-8): Clon del juego Civilization |
22 | Summary(pl.UTF-8): Niekomercyjny klon CIVilization | |
23 | Summary(pt_BR.UTF-8): Clone do jogo Civilization | |
68badbcf | 24 | Name: freeciv |
b588d51d | 25 | Version: 2.4.4 |
7a1462a3 | 26 | Release: 0.3 |
d9c0a687 | 27 | License: GPL v2+ |
c4d7f9a4 | 28 | Group: X11/Applications/Games/Strategy |
53427aff | 29 | Source0: http://downloads.sourceforge.net/freeciv/%{name}-%{version}.tar.bz2 |
b588d51d | 30 | # Source0-md5: 038c53184497fcf31bcd268418dbe4f6 |
f1481f57 | 31 | # NOTE: current version of freeland tiles does not work with newest freeciv version |
32 | #Source1: http://download.gna.org/freeciv/contrib/tilesets/freeland/freeland-normal-2.0.0.tar.gz | |
a2d6e64d | 33 | Patch0: %{name}-link.patch |
7d71a717 | 34 | Patch1: %{name}-desktop.patch |
f8f12eb9 | 35 | Patch2: %{name}-ggz.patch |
999b152c | 36 | URL: http://freeciv.wikia.com/ |
1304e7cf | 37 | %{?with_magickwand:BuildRequires: ImageMagick-devel} |
73fd6aa7 | 38 | %if %{with sdl} |
d00642ee | 39 | BuildRequires: SDL_image-devel |
37e4bbeb | 40 | BuildRequires: SDL_mixer-devel |
73fd6aa7 | 41 | %endif |
a2d6e64d | 42 | BuildRequires: autoconf >= 2.52 |
744dee41 | 43 | BuildRequires: automake >= 1:1.9 |
b256fc05 | 44 | BuildRequires: curl-devel |
076a3f05 | 45 | BuildRequires: gettext-tools |
3de6f65c | 46 | %{?with_ggz_client:BuildRequires: ggz-gtk-client-devel} |
73fd6aa7 SS |
47 | %{?with_gtk2:BuildRequires: gtk+2-devel} |
48 | %{?with_gtk3:BuildRequires: gtk+3-devel} | |
3de6f65c | 49 | BuildRequires: libggz-devel |
c9f99b35 | 50 | BuildRequires: libpng-devel |
ef569fe1 | 51 | BuildRequires: libtool |
60163dd9 | 52 | %{?with_system_lua:BuildRequires: lua51-devel} |
a2d6e64d | 53 | BuildRequires: pkgconfig |
848e1b5f | 54 | BuildRequires: readline-devel |
73fd6aa7 | 55 | %{?with_xaw:BuildRequires: xorg-lib-libXaw-devel} |
848e1b5f | 56 | BuildRequires: zlib-devel |
254af51f | 57 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
512c4044 | 58 | |
4bd37832 | 59 | %define specflags -O1 |
60 | ||
8e6171b1 | 61 | %description |
52afb265 | 62 | Free clone of Sid Meier's Civilization. Free Civilization clone for |
20965c93 | 63 | Unix and X. This is multiplayer strategic game and you can also play |
54c8b158 | 64 | against computer-AI players. |
8e6171b1 | 65 | |
8b555401 | 66 | %description -l es.UTF-8 |
eba39772 | 67 | Clon del juego Civilization. |
68 | ||
8b555401 | 69 | %description -l pl.UTF-8 |
c55f1852 | 70 | Freeciv jest to niekomercyjny (GPL) klon gry Civilization Sida Meiera. |
8b555401 | 71 | Jest to gra strategiczna dla systemu X Window. Można grać w nią z |
e64b1569 JB |
72 | innymi osobami poprzez sieć, a także przeciwko "graczom" zarządzanym |
73 | przez komputer. | |
8e6171b1 | 74 | |
8b555401 JR |
75 | %description -l pt_BR.UTF-8 |
76 | O FreeCiv é uma implementação do Civilization II para o Sistema X | |
eba39772 | 77 | Window. |
78 | ||
c55f1852 | 79 | %package client |
7a1462a3 SS |
80 | Summary: GTK2 Freeciv game client |
81 | Summary(pl.UTF-8): Klient gry Freeciv korzystający z GTK2 | |
c55f1852 | 82 | Group: X11/Applications/Games/Strategy |
83 | Requires: %{name} = %{version}-%{release} | |
7a1462a3 | 84 | Requires: %{name}-client-common = %{version}-%{release} |
6a3d034a | 85 | Suggests: %{name}-server = %{version}-%{release} |
c55f1852 | 86 | |
87 | %description client | |
7a1462a3 | 88 | This package contains GTK2-based Freeciv game client. |
c55f1852 | 89 | |
8b555401 | 90 | %description client -l pl.UTF-8 |
7a1462a3 SS |
91 | Ten pakiet zawiera klienta gry Freeciv korzystającego z GTK2. |
92 | ||
93 | %package client-common | |
94 | Summary: Freeciv game client common files | |
95 | Summary(pl.UTF-8): Wspólne pliki klientów gry Freeciv | |
96 | Group: X11/Applications/Games/Strategy | |
97 | Requires: %{name} = %{version}-%{release} | |
98 | Requires: %{name}-client-common = %{version}-%{release} | |
99 | Suggests: %{name}-server = %{version}-%{release} | |
100 | ||
101 | %description client-common | |
102 | This package contains common files for Freeciv game clients. | |
103 | ||
104 | %description client-common -l pl.UTF-8 | |
105 | Ten pakiet zawiera wspólne pliki dla klientów gry Freeciv. | |
106 | ||
107 | %package client-gtk3 | |
108 | Summary: GTK3 Freeciv game client | |
109 | Summary(pl.UTF-8): Klient gry Freeciv korzystający z GTK3 | |
110 | Group: X11/Applications/Games/Strategy | |
111 | Requires: %{name} = %{version}-%{release} | |
112 | Suggests: %{name}-server = %{version}-%{release} | |
113 | ||
114 | %description client-gtk3 | |
115 | This package contains GTK3-based Freeciv game client. | |
116 | ||
117 | %description client-gtk3 -l pl.UTF-8 | |
118 | Ten pakiet zawiera klienta gry Freeciv korzystającego z GTK3. | |
119 | ||
120 | %package client-sdl | |
121 | Summary: SDL Freeciv game client | |
122 | Summary(pl.UTF-8): Klient gry Freeciv korzystający z SDL | |
123 | Group: X11/Applications/Games/Strategy | |
124 | Requires: %{name} = %{version}-%{release} | |
125 | Requires: %{name}-client-common = %{version}-%{release} | |
126 | Requires: SDL_mixer | |
127 | Suggests: %{name}-server = %{version}-%{release} | |
128 | ||
129 | %description client-sdl | |
130 | This package contains SDL-based Freeciv game client. | |
131 | ||
132 | %description client-sdl -l pl.UTF-8 | |
133 | Ten pakiet zawiera klienta gry Freeciv korzystającego z SDL. | |
134 | ||
135 | %package client-xaw | |
136 | Summary: XAW Freeciv game client | |
137 | Summary(pl.UTF-8): Klient gry Freeciv korzystający z XAW | |
138 | Group: X11/Applications/Games/Strategy | |
139 | Requires: %{name} = %{version}-%{release} | |
140 | Requires: %{name}-client-common = %{version}-%{release} | |
141 | Suggests: %{name}-server = %{version}-%{release} | |
142 | ||
143 | %description client-xaw | |
144 | This package contains based Freeciv game client using XAW (X Athena | |
145 | Widgets). | |
146 | ||
147 | %description client-xaw -l pl.UTF-8 | |
148 | Ten pakiet zawiera klienta gry Freeciv korzystającego z biblioteki XAW | |
149 | (X Athena Widgets) | |
150 | ||
151 | %package client-modpack | |
152 | Summary: Custom content installer for the Freeciv game | |
153 | Summary(pl.UTF-8): Instalator dodatków do gry Freeciv | |
154 | Group: X11/Applications/Games/Strategy | |
155 | Requires: %{name} = %{version}-%{release} | |
156 | Requires: %{name}-client-common = %{version}-%{release} | |
157 | Suggests: %{name}-server = %{version}-%{release} | |
158 | ||
159 | %description client-modpack | |
160 | Custom content installer for the Freeciv game. | |
161 | ||
162 | This program allows users to select and download add-on content | |
163 | ("modpacks") for Freeciv from the Internet, either from a list | |
164 | maintained by the Freeciv team, or by using a URL obtained by other | |
165 | means. It takes care of installing the files in the correct place | |
166 | under the user's home directory for this version of Freeciv; it does | |
167 | not install anything for system-wide use. | |
168 | ||
169 | %description client-modpack -l pl.UTF-8 | |
170 | Ten pakiet zawiera instalator dodatków do gry Freeciv dostępnych w | |
171 | internecie. | |
c55f1852 | 172 | |
c55f1852 | 173 | %package server |
174 | Summary: Freeciv game server | |
a2d6e64d | 175 | Summary(pl.UTF-8): Serwer gry Freeciv |
c55f1852 | 176 | Group: X11/Applications/Games/Strategy |
177 | Requires: %{name} = %{version}-%{release} | |
178 | ||
179 | %description server | |
180 | This package contans Freeciv game server. | |
181 | ||
8b555401 | 182 | %description server -l pl.UTF-8 |
c55f1852 | 183 | Ten pakiet zawiera server gry Freeciv. |
184 | ||
8e6171b1 | 185 | %prep |
f1481f57 | 186 | %setup -q |
a2d6e64d | 187 | %patch0 -p1 |
293a1d81 | 188 | %patch1 -p1 |
f8f12eb9 | 189 | %patch2 -p1 |
8e6171b1 | 190 | |
191 | %build | |
e748604f | 192 | %{__libtoolize} |
f8f12eb9 | 193 | %{__aclocal} -I m4 |
a2d6e64d | 194 | %{__autoconf} |
195 | %{__autoheader} | |
196 | %{__automake} | |
197 | %configure \ | |
f8f12eb9 | 198 | --with-ggzd-confdir=%{_sysconfdir}/ggzd \ |
82c4aa50 | 199 | --disable-silent-rules \ |
73fd6aa7 | 200 | --enable-client=stub,%{?with_gtk2:gtk2},%{?with_gtk3:gtk3},%{?with_qt:qt},%{?with_sdl:sdl},%{?with_xaw:xaw} \ |
1304e7cf | 201 | --enable-mapimg=%{?with_magickwand:magickwand}%{!?with_magickwand:no} \ |
60163dd9 | 202 | %{?with_system_lua:--enable-sys-lua} \ |
999b152c ER |
203 | %{!?with_ggz_client:--without-ggz-client} \ |
204 | %{!?with_ggz_server:--without-ggz-server} | |
a2d6e64d | 205 | |
1402ce58 | 206 | %{__make} |
8e6171b1 | 207 | |
208 | %install | |
209 | rm -rf $RPM_BUILD_ROOT | |
a2d6e64d | 210 | install -d $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir}} |
8e6171b1 | 211 | |
7eec69ca PG |
212 | %{__make} install \ |
213 | DESTDIR=$RPM_BUILD_ROOT | |
8e6171b1 | 214 | |
999b152c ER |
215 | cp -a client/%{name}.desktop $RPM_BUILD_ROOT%{_desktopdir}/%{name}-client.desktop |
216 | cp -a server/%{name}-server.desktop $RPM_BUILD_ROOT%{_desktopdir} | |
320ce787 | 217 | %{__rm} -f $RPM_BUILD_ROOT%{_desktopdir}/%{name}.desktop |
90745ade | 218 | |
999b152c ER |
219 | cp -a data/icons/32x32/*.png $RPM_BUILD_ROOT%{_pixmapsdir} |
220 | cp -a data/stdsounds{,.soundspec} $RPM_BUILD_ROOT%{_datadir}/%{name} | |
ac951725 | 221 | #cp -a freeland.tilespec $RPM_BUILD_ROOT%{_datadir}/%{name} |
1f960d6b | 222 | #cp -a freeland $RPM_BUILD_ROOT%{_datadir}/%{name} |
38b7e0fd | 223 | |
37e4bbeb | 224 | %{__rm} -r $RPM_BUILD_ROOT%{_localedir}/no |
320ce787 | 225 | %{__rm} -f $RPM_BUILD_ROOT%{_sysconfdir}/ggz.modules |
a2d6e64d | 226 | |
24382cc8 | 227 | cp -a data/gtk_menus.xml $RPM_BUILD_ROOT%{_datadir}/%{name} |
b274a5f1 | 228 | |
dc958ef7 | 229 | %if %{with ggz_server} |
230 | install -d $RPM_BUILD_ROOT%{_sysconfdir}/ggzd/{games,rooms} | |
999b152c ER |
231 | cp -a data/civserver.dsc $RPM_BUILD_ROOT%{_sysconfdir}/ggzd/games/civserver.dsc |
232 | cp -a data/civserver.room $RPM_BUILD_ROOT%{_sysconfdir}/ggzd/rooms/civserver.room | |
dc958ef7 | 233 | %endif |
234 | ||
37e4bbeb | 235 | %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name} |
cce99d3e | 236 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libfreeciv{,-srv}.{a,la} |
60817f48 | 237 | %{__rm} $RPM_BUILD_ROOT%{_mandir}/man6/freeciv-qt* |
cce99d3e | 238 | |
a13c0015 SS |
239 | # from freeciv-manual man: |
240 | # This tool is currently only really of use to the Freeciv maintainers, | |
241 | # as a starting point for pages on the main Freeciv wiki; | |
242 | # it's not very useful to end users. | |
243 | %{__rm} $RPM_BUILD_ROOT%{_bindir}/freeciv-manual | |
244 | %{__rm} $RPM_BUILD_ROOT%{_mandir}/man6/freeciv-manual* | |
245 | ||
10c5731a | 246 | %find_lang %{name} |
247 | ||
8e6171b1 | 248 | %clean |
249 | rm -rf $RPM_BUILD_ROOT | |
250 | ||
10c5731a | 251 | %files -f %{name}.lang |
063665a5 | 252 | %defattr(644,root,root,755) |
2770169a SS |
253 | %doc AUTHORS doc/BUGS ChangeLog doc/FAQ doc/HOWTOPLAY |
254 | %doc NEWS NEWS-2.4 | |
255 | %doc doc/README.SDLClient doc/README.cma doc/README.effects doc/README.fcdb | |
256 | %doc doc/README.graphics doc/README.sound | |
257 | %doc doc/README.ruleset_experimental doc/README.ruleset_multiplayer doc/README.rulesets | |
258 | %doc doc/TODO | |
70461273 | 259 | %dir %{_datadir}/%{name} |
c55f1852 | 260 | %{_datadir}/%{name}/helpdata.txt |
261 | ||
262 | %files server | |
263 | %defattr(644,root,root,755) | |
e748604f | 264 | %attr(755,root,root) %{_bindir}/freeciv-server |
a13c0015 | 265 | #attr(755,root,root) %{_bindir}/freeciv-manual |
c55f1852 | 266 | %{_desktopdir}/%{name}-server.desktop |
6c98e562 | 267 | %{_datadir}/appdata/freeciv-server.appdata.xml |
c55f1852 | 268 | %{_datadir}/%{name}/civ1 |
269 | %{_datadir}/%{name}/civ2 | |
270 | %{_datadir}/%{name}/default | |
9f0b2873 | 271 | %{_datadir}/%{name}/experimental |
272 | %{_datadir}/%{name}/multiplayer | |
c55f1852 | 273 | %{_datadir}/%{name}/nation |
9c8a8e09 | 274 | %{_datadir}/%{name}/scenarios |
c55f1852 | 275 | %{_datadir}/%{name}/*.serv |
e748604f | 276 | %{_mandir}/man6/freeciv-server.6* |
a13c0015 | 277 | #{_mandir}/man6/freeciv-manual.6* |
e748604f | 278 | %{_iconsdir}/hicolor/*/apps/freeciv-server.png |
279 | %{_pixmapsdir}/freeciv-server.png | |
a336af56 ER |
280 | |
281 | %if %{with ggz_server} | |
282 | %dir %{_sysconfdir}/ggzd | |
283 | %dir %{_sysconfdir}/ggzd/games | |
284 | %dir %{_sysconfdir}/ggzd/rooms | |
285 | %{_sysconfdir}/ggzd/games/civserver.dsc | |
286 | %{_sysconfdir}/ggzd/rooms/civserver.room | |
287 | %endif | |
c55f1852 | 288 | |
7a1462a3 | 289 | %files client-common |
c55f1852 | 290 | %defattr(644,root,root,755) |
2dc46003 | 291 | %attr(755,root,root) %{_bindir}/freeciv-stub |
90745ade | 292 | %{_datadir}/%{name}/*.*spec |
9f0b2873 | 293 | %{_datadir}/%{name}/amplio2 |
90745ade | 294 | %{_datadir}/%{name}/buildings |
6223fa29 | 295 | %{_datadir}/%{name}/cimpletoon |
90745ade | 296 | %{_datadir}/%{name}/flags |
24382cc8 | 297 | %{_datadir}/%{name}/gtk_menus.xml |
90745ade | 298 | %{_datadir}/%{name}/hex2t |
d9c0a687 | 299 | %{_datadir}/%{name}/isophex |
c55f1852 | 300 | %{_datadir}/%{name}/isotrident |
301 | %{_datadir}/%{name}/misc | |
a2d6e64d | 302 | %{_datadir}/%{name}/stdsounds |
90745ade JK |
303 | %{_datadir}/%{name}/themes |
304 | %{_datadir}/%{name}/trident | |
305 | %{_datadir}/%{name}/wonders | |
7a1462a3 SS |
306 | |
307 | %files client-modpack | |
308 | %defattr(644,root,root,755) | |
309 | %attr(755,root,root) %{_bindir}/freeciv-modpack | |
310 | %{_desktopdir}/%{name}-modpack.desktop | |
311 | %{_datadir}/appdata/freeciv-modpack.appdata.xml | |
312 | %{_iconsdir}/hicolor/*/apps/freeciv-modpack.png | |
313 | %{_pixmapsdir}/freeciv-modpack.png | |
314 | %{_mandir}/man6/freeciv-modpack.6* | |
315 | ||
316 | %if %{with gtk2} | |
317 | %files client | |
318 | %defattr(644,root,root,755) | |
319 | %attr(755,root,root) %{_bindir}/freeciv-gtk2 | |
320 | %{_desktopdir}/%{name}-client.desktop | |
321 | %{_datadir}/appdata/freeciv-gtk2.appdata.xml | |
320ce787 | 322 | %{_datadir}/%{name}/freeciv.rc-2.0 |
e748604f | 323 | %{_mandir}/man6/freeciv-client.6* |
324 | %{_mandir}/man6/freeciv-gtk2.6* | |
7a1462a3 SS |
325 | %{_iconsdir}/hicolor/*/apps/freeciv-client.png |
326 | %{_pixmapsdir}/freeciv-client.png | |
327 | %endif | |
328 | ||
329 | %if %{with gtk3} | |
330 | %files client-gtk3 | |
331 | %defattr(644,root,root,755) | |
332 | %attr(755,root,root) %{_bindir}/freeciv-gtk3 | |
333 | %{_desktopdir}/%{name}-gtk3.desktop | |
334 | %{_datadir}/appdata/freeciv-gtk3.appdata.xml | |
a5977815 | 335 | %{_mandir}/man6/freeciv-gtk3.6* |
7a1462a3 SS |
336 | %endif |
337 | ||
338 | %if %{with sdl} | |
339 | %files client-sdl | |
340 | %defattr(644,root,root,755) | |
341 | %attr(755,root,root) %{_bindir}/freeciv-sdl | |
342 | %{_desktopdir}/%{name}-sdl.desktop | |
343 | %{_datadir}/appdata/freeciv-sdl.appdata.xml | |
c3f6abd3 | 344 | %{_mandir}/man6/freeciv-sdl.6* |
7a1462a3 SS |
345 | %endif |
346 | ||
347 | %if %{with xaw} | |
348 | %files client-xaw | |
349 | %defattr(644,root,root,755) | |
350 | %attr(755,root,root) %{_bindir}/freeciv-xaw | |
351 | %{_datadir}/%{name}/Freeciv | |
c3f6abd3 | 352 | %{_mandir}/man6/freeciv-xaw.6* |
7a1462a3 | 353 | %endif |
6223fa29 | 354 |