3 # - work on authentication and Freeciv database support (fcdb)
4 # - patch all packaged desktop files
5 # - modpack requires gtk2 or gtk3
8 %bcond_without ggz_client # build without ggz client
9 %bcond_without ggz_server # build without ggz server
10 %bcond_without magickwand # build without MagickWand map image toolkit support
11 %bcond_without system_lua # build with bundled lua
12 %bcond_without gtk2 # build without gtk2 client
13 %bcond_without gtk3 # build without gtk3 client
14 %bcond_without sdl # build without sdl client
15 %bcond_without xaw # build without xaw client
16 %bcond_with qt # build with qt client (broken)
17 %bcond_without modpack # build without modpack installer
19 Summary: FREE CIVilization clone
20 Summary(es.UTF-8): Clon del juego Civilization
21 Summary(pl.UTF-8): Niekomercyjny klon CIVilization
22 Summary(pt_BR.UTF-8): Clone do jogo Civilization
27 Group: X11/Applications/Games/Strategy
28 Source0: http://downloads.sourceforge.net/freeciv/%{name}-%{version}.tar.bz2
29 # Source0-md5: 038c53184497fcf31bcd268418dbe4f6
30 # NOTE: current version of freeland tiles does not work with newest freeciv version
31 #Source1: http://download.gna.org/freeciv/contrib/tilesets/freeland/freeland-normal-2.0.0.tar.gz
32 Patch0: %{name}-link.patch
33 Patch1: %{name}-desktop.patch
34 Patch2: %{name}-ggz.patch
35 URL: http://freeciv.wikia.com/
36 %{?with_magickwand:BuildRequires: ImageMagick-devel}
37 %{?with_sdl:BuildRequires: SDL_image-devel}
38 BuildRequires: SDL_mixer-devel
39 BuildRequires: autoconf >= 2.52
40 BuildRequires: automake >= 1:1.9
41 BuildRequires: curl-devel
42 BuildRequires: gettext-tools
43 %{?with_ggz_client:BuildRequires: ggz-gtk-client-devel}
44 %{?with_gtk2:BuildRequires: gtk+2-devel}
45 %{?with_gtk3:BuildRequires: gtk+3-devel}
46 BuildRequires: libggz-devel
47 BuildRequires: libpng-devel
48 BuildRequires: libtool
49 %{?with_system_lua:BuildRequires: lua51-devel}
50 BuildRequires: pkgconfig
51 BuildRequires: readline-devel
52 %{?with_xaw:BuildRequires: xorg-lib-libXaw-devel}
53 BuildRequires: zlib-devel
54 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
59 Free clone of Sid Meier's Civilization. Free Civilization clone for
60 Unix and X. This is multiplayer strategic game and you can also play
61 against computer-AI players.
63 %description -l es.UTF-8
64 Clon del juego Civilization.
66 %description -l pl.UTF-8
67 Freeciv jest to niekomercyjny (GPL) klon gry Civilization Sida Meiera.
68 Jest to gra strategiczna dla systemu X Window. Można grać w nią z
69 innymi osobami poprzez sieć, a także przeciwko "graczom" zarządzanym
72 %description -l pt_BR.UTF-8
73 O FreeCiv é uma implementação do Civilization II para o Sistema X
77 Summary: GTK2 Freeciv game client
78 Summary(pl.UTF-8): Klient gry Freeciv korzystający z GTK2
79 Group: X11/Applications/Games/Strategy
80 Requires: %{name} = %{version}-%{release}
81 Requires: %{name}-client-common = %{version}-%{release}
82 Suggests: %{name}-server = %{version}-%{release}
85 This package contains GTK2-based Freeciv game client.
87 %description client -l pl.UTF-8
88 Ten pakiet zawiera klienta gry Freeciv korzystającego z GTK2.
90 %package client-common
91 Summary: Freeciv game client common files
92 Summary(pl.UTF-8): Wspólne pliki klientów gry Freeciv
93 Group: X11/Applications/Games/Strategy
94 Requires: %{name} = %{version}-%{release}
96 Suggests: %{name}-server = %{version}-%{release}
98 %description client-common
99 This package contains common files for Freeciv game clients.
101 %description client-common -l pl.UTF-8
102 Ten pakiet zawiera wspólne pliki dla klientów gry Freeciv.
105 Summary: GTK3 Freeciv game client
106 Summary(pl.UTF-8): Klient gry Freeciv korzystający z GTK3
107 Group: X11/Applications/Games/Strategy
108 Requires: %{name} = %{version}-%{release}
109 Suggests: %{name}-server = %{version}-%{release}
111 %description client-gtk3
112 This package contains GTK3-based Freeciv game client.
114 %description client-gtk3 -l pl.UTF-8
115 Ten pakiet zawiera klienta gry Freeciv korzystającego z GTK3.
118 Summary: SDL Freeciv game client
119 Summary(pl.UTF-8): Klient gry Freeciv korzystający z SDL
120 Group: X11/Applications/Games/Strategy
121 Requires: %{name} = %{version}-%{release}
122 Requires: %{name}-client-common = %{version}-%{release}
123 Suggests: %{name}-server = %{version}-%{release}
125 %description client-sdl
126 This package contains SDL-based Freeciv game client.
128 %description client-sdl -l pl.UTF-8
129 Ten pakiet zawiera klienta gry Freeciv korzystającego z SDL.
132 Summary: XAW Freeciv game client
133 Summary(pl.UTF-8): Klient gry Freeciv korzystający z XAW
134 Group: X11/Applications/Games/Strategy
135 Requires: %{name} = %{version}-%{release}
136 Requires: %{name}-client-common = %{version}-%{release}
137 Suggests: %{name}-server = %{version}-%{release}
139 %description client-xaw
140 This package contains based Freeciv game client using XAW (X Athena
143 %description client-xaw -l pl.UTF-8
144 Ten pakiet zawiera klienta gry Freeciv korzystającego z biblioteki XAW
148 Summary: Custom content installer for the Freeciv game
149 Summary(pl.UTF-8): Instalator dodatków do gry Freeciv
150 Group: X11/Applications/Games/Strategy
151 Requires: %{name} = %{version}-%{release}
152 Requires: %{name}-client-common = %{version}-%{release}
153 Suggests: %{name}-server = %{version}-%{release}
156 Custom content installer for the Freeciv game.
158 This program allows users to select and download add-on content
159 ("modpacks") for Freeciv from the Internet, either from a list
160 maintained by the Freeciv team, or by using a URL obtained by other
161 means. It takes care of installing the files in the correct place
162 under the user's home directory for this version of Freeciv; it does
163 not install anything for system-wide use.
165 %description modpack -l pl.UTF-8
166 Ten pakiet zawiera instalator dodatków do gry Freeciv dostępnych w
170 Summary: Freeciv game server
171 Summary(pl.UTF-8): Serwer gry Freeciv
172 Group: X11/Applications/Games/Strategy
173 Requires: %{name} = %{version}-%{release}
176 This package contans Freeciv game server.
178 %description server -l pl.UTF-8
179 Ten pakiet zawiera server gry Freeciv.
194 --with-ggzd-confdir=%{_sysconfdir}/ggzd \
195 --disable-silent-rules \
196 --enable-client=stub,%{?with_gtk2:gtk2},%{?with_gtk3:gtk3},%{?with_qt:qt},%{?with_sdl:sdl},%{?with_xaw:xaw} \
197 --enable-mapimg=%{?with_magickwand:magickwand}%{!?with_magickwand:no} \
198 %{!?with_modpack:--enable-fcmp=no} \
199 %{?with_system_lua:--enable-sys-lua} \
200 %{!?with_ggz_client:--without-ggz-client} \
201 %{!?with_ggz_server:--without-ggz-server}
206 rm -rf $RPM_BUILD_ROOT
207 install -d $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir}}
210 DESTDIR=$RPM_BUILD_ROOT
212 cp -a client/%{name}.desktop $RPM_BUILD_ROOT%{_desktopdir}/%{name}-client.desktop
213 cp -a server/%{name}-server.desktop $RPM_BUILD_ROOT%{_desktopdir}
214 %{__rm} -f $RPM_BUILD_ROOT%{_desktopdir}/%{name}.desktop
216 cp -a data/icons/32x32/*.png $RPM_BUILD_ROOT%{_pixmapsdir}
217 cp -a data/stdsounds{,.soundspec} $RPM_BUILD_ROOT%{_datadir}/%{name}
218 #cp -a freeland.tilespec $RPM_BUILD_ROOT%{_datadir}/%{name}
219 #cp -a freeland $RPM_BUILD_ROOT%{_datadir}/%{name}
221 %{__rm} -r $RPM_BUILD_ROOT%{_localedir}/no
222 %{__rm} -f $RPM_BUILD_ROOT%{_sysconfdir}/ggz.modules
224 cp -a data/gtk_menus.xml $RPM_BUILD_ROOT%{_datadir}/%{name}
226 %if %{with ggz_server}
227 install -d $RPM_BUILD_ROOT%{_sysconfdir}/ggzd/{games,rooms}
228 cp -a data/civserver.dsc $RPM_BUILD_ROOT%{_sysconfdir}/ggzd/games/civserver.dsc
229 cp -a data/civserver.room $RPM_BUILD_ROOT%{_sysconfdir}/ggzd/rooms/civserver.room
232 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}
233 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libfreeciv{,-srv}.{a,la}
234 %{__rm} $RPM_BUILD_ROOT%{_mandir}/man6/freeciv-qt*
236 # from freeciv-manual man:
237 # This tool is currently only really of use to the Freeciv maintainers,
238 # as a starting point for pages on the main Freeciv wiki;
239 # it's not very useful to end users.
240 %{__rm} $RPM_BUILD_ROOT%{_bindir}/freeciv-manual
241 %{__rm} $RPM_BUILD_ROOT%{_mandir}/man6/freeciv-manual*
243 %{__rm} $RPM_BUILD_ROOT%{_bindir}/freeciv-stub
245 # needed if building --without gtk2,gtk3,sdl
246 %{__install} -d $RPM_BUILD_ROOT%{_datadir}/%{name}/themes
251 rm -rf $RPM_BUILD_ROOT
253 %files -f %{name}.lang
254 %defattr(644,root,root,755)
255 %doc AUTHORS doc/BUGS ChangeLog doc/FAQ doc/HOWTOPLAY
257 %doc doc/README.SDLClient doc/README.cma doc/README.effects doc/README.fcdb
258 %doc doc/README.graphics doc/README.sound
259 %doc doc/README.ruleset_experimental doc/README.ruleset_multiplayer doc/README.rulesets
261 %dir %{_datadir}/%{name}
262 %{_datadir}/%{name}/helpdata.txt
265 %defattr(644,root,root,755)
266 %attr(755,root,root) %{_bindir}/freeciv-server
267 #attr(755,root,root) %{_bindir}/freeciv-manual
268 %{_desktopdir}/%{name}-server.desktop
269 %{_datadir}/appdata/freeciv-server.appdata.xml
270 %{_datadir}/%{name}/civ1
271 %{_datadir}/%{name}/civ2
272 %{_datadir}/%{name}/default
273 %{_datadir}/%{name}/experimental
274 %{_datadir}/%{name}/multiplayer
275 %{_datadir}/%{name}/nation
276 %{_datadir}/%{name}/scenarios
277 %{_datadir}/%{name}/*.serv
278 %{_mandir}/man6/freeciv-server.6*
279 #{_mandir}/man6/freeciv-manual.6*
280 %{_iconsdir}/hicolor/*/apps/freeciv-server.png
281 %{_pixmapsdir}/freeciv-server.png
283 %if %{with ggz_server}
284 %dir %{_sysconfdir}/ggzd
285 %dir %{_sysconfdir}/ggzd/games
286 %dir %{_sysconfdir}/ggzd/rooms
287 %{_sysconfdir}/ggzd/games/civserver.dsc
288 %{_sysconfdir}/ggzd/rooms/civserver.room
292 %defattr(644,root,root,755)
293 %{_datadir}/%{name}/*.*spec
294 %{_datadir}/%{name}/amplio2
295 %{_datadir}/%{name}/buildings
296 %{_datadir}/%{name}/cimpletoon
297 %{_datadir}/%{name}/flags
298 %{_datadir}/%{name}/gtk_menus.xml
299 %{_datadir}/%{name}/hex2t
300 %{_datadir}/%{name}/isophex
301 %{_datadir}/%{name}/isotrident
302 %{_datadir}/%{name}/misc
303 %{_datadir}/%{name}/stdsounds
304 %dir %{_datadir}/%{name}/themes
305 %{_datadir}/%{name}/trident
306 %{_datadir}/%{name}/wonders
310 %defattr(644,root,root,755)
311 %attr(755,root,root) %{_bindir}/freeciv-modpack
312 %{_desktopdir}/%{name}-modpack.desktop
313 %{_datadir}/appdata/freeciv-modpack.appdata.xml
314 %{_iconsdir}/hicolor/*/apps/freeciv-modpack.png
315 %{_pixmapsdir}/freeciv-modpack.png
316 %{_mandir}/man6/freeciv-modpack.6*
321 %defattr(644,root,root,755)
322 %attr(755,root,root) %{_bindir}/freeciv-gtk2
323 %{_desktopdir}/%{name}-client.desktop
324 %{_datadir}/appdata/freeciv-gtk2.appdata.xml
325 %{_datadir}/%{name}/freeciv.rc-2.0
326 %{_datadir}/%{name}/themes/gui-gtk-2.0
327 %{_mandir}/man6/freeciv-client.6*
328 %{_mandir}/man6/freeciv-gtk2.6*
329 %{_iconsdir}/hicolor/*/apps/freeciv-client.png
330 %{_pixmapsdir}/freeciv-client.png
335 %defattr(644,root,root,755)
336 %attr(755,root,root) %{_bindir}/freeciv-gtk3
337 %{_desktopdir}/%{name}-gtk3.desktop
338 %{_datadir}/appdata/freeciv-gtk3.appdata.xml
339 %{_datadir}/%{name}/themes/gui-gtk-3.0
340 %{_mandir}/man6/freeciv-gtk3.6*
345 %defattr(644,root,root,755)
346 %attr(755,root,root) %{_bindir}/freeciv-sdl
347 %{_desktopdir}/%{name}-sdl.desktop
348 %{_datadir}/appdata/freeciv-sdl.appdata.xml
349 %{_datadir}/%{name}/themes/gui-sdl
350 %{_mandir}/man6/freeciv-sdl.6*
355 %defattr(644,root,root,755)
356 %attr(755,root,root) %{_bindir}/freeciv-xaw
357 %{_datadir}/%{name}/Freeciv
358 %{_mandir}/man6/freeciv-xaw.6*