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