]>
Commit | Line | Data |
---|---|---|
1 | # | |
2 | # TODO: - try to create bconds for supported clients | |
3 | # - separate desktop files for all clients | |
4 | # | |
5 | # Conditional build: | |
6 | %bcond_without ggz_client # build without ggz client | |
7 | %bcond_without ggz_server # build without ggz server | |
8 | # | |
9 | Summary: FREE CIVilization clone | |
10 | Summary(es.UTF-8): Clon del juego Civilization | |
11 | Summary(pl.UTF-8): Niekomercyjny klon CIVilization | |
12 | Summary(pt_BR.UTF-8): Clone do jogo Civilization | |
13 | Name: freeciv | |
14 | Version: 2.4.4 | |
15 | Release: 0.2 | |
16 | License: GPL v2+ | |
17 | Group: X11/Applications/Games/Strategy | |
18 | Source0: http://downloads.sourceforge.net/freeciv/%{name}-%{version}.tar.bz2 | |
19 | # Source0-md5: 038c53184497fcf31bcd268418dbe4f6 | |
20 | # NOTE: current version of freeland tiles does not work with newest freeciv version | |
21 | #Source1: http://download.gna.org/freeciv/contrib/tilesets/freeland/freeland-normal-2.0.0.tar.gz | |
22 | Patch0: %{name}-link.patch | |
23 | Patch1: %{name}-desktop.patch | |
24 | Patch2: %{name}-ggz.patch | |
25 | URL: http://freeciv.wikia.com/ | |
26 | BuildRequires: SDL_mixer-devel | |
27 | BuildRequires: SDL_image-devel | |
28 | BuildRequires: autoconf >= 2.52 | |
29 | BuildRequires: automake | |
30 | BuildRequires: gettext-tools | |
31 | %{?with_ggz_client:BuildRequires: ggz-gtk-client-devel} | |
32 | BuildRequires: gtk+2-devel | |
33 | BuildRequires: libggz-devel | |
34 | BuildRequires: libpng-devel | |
35 | BuildRequires: libtool | |
36 | BuildRequires: pkgconfig | |
37 | BuildRequires: readline-devel | |
38 | BuildRequires: xorg-lib-libXaw-devel | |
39 | BuildRequires: zlib-devel | |
40 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
41 | ||
42 | %define specflags -O1 | |
43 | ||
44 | %description | |
45 | Free clone of Sid Meier's Civilization. Free Civilization clone for | |
46 | Unix and X. This is multiplayer strategic game and you can also play | |
47 | against computer-AI players. | |
48 | ||
49 | %description -l es.UTF-8 | |
50 | Clon del juego Civilization. | |
51 | ||
52 | %description -l pl.UTF-8 | |
53 | Freeciv jest to niekomercyjny (GPL) klon gry Civilization Sida Meiera. | |
54 | Jest to gra strategiczna dla systemu X Window. Można grać w nią z | |
55 | innymi osobami poprzez sieć, a także przeciwko "graczom" zarządzanym | |
56 | przez komputer. | |
57 | ||
58 | %description -l pt_BR.UTF-8 | |
59 | O FreeCiv é uma implementação do Civilization II para o Sistema X | |
60 | Window. | |
61 | ||
62 | %package client | |
63 | Summary: Freeciv game client | |
64 | Summary(pl.UTF-8): Klient gry Freeciv | |
65 | Group: X11/Applications/Games/Strategy | |
66 | Requires: %{name} = %{version}-%{release} | |
67 | Requires: SDL_mixer | |
68 | Suggests: %{name}-server = %{version}-%{release} | |
69 | ||
70 | %description client | |
71 | This package contains Freeciv game client. | |
72 | ||
73 | %description client -l pl.UTF-8 | |
74 | Ten pakiet zawiera klienta gry Freeciv. | |
75 | ||
76 | %package server | |
77 | Summary: Freeciv game server | |
78 | Summary(pl.UTF-8): Serwer gry Freeciv | |
79 | Group: X11/Applications/Games/Strategy | |
80 | Requires: %{name} = %{version}-%{release} | |
81 | ||
82 | %description server | |
83 | This package contans Freeciv game server. | |
84 | ||
85 | %description server -l pl.UTF-8 | |
86 | Ten pakiet zawiera server gry Freeciv. | |
87 | ||
88 | %prep | |
89 | %setup -q | |
90 | %patch0 -p1 | |
91 | #patch1 -p1 | |
92 | %patch2 -p1 | |
93 | ||
94 | %build | |
95 | %{__libtoolize} | |
96 | %{__aclocal} -I m4 | |
97 | %{__autoconf} | |
98 | %{__autoheader} | |
99 | %{__automake} | |
100 | %configure \ | |
101 | --with-ggzd-confdir=%{_sysconfdir}/ggzd \ | |
102 | --disable-silent-rules \ | |
103 | --enable-client=gtk2,gtk3,sdl,xaw,stub \ | |
104 | %{!?with_ggz_client:--without-ggz-client} \ | |
105 | %{!?with_ggz_server:--without-ggz-server} | |
106 | ||
107 | %{__make} | |
108 | ||
109 | %install | |
110 | rm -rf $RPM_BUILD_ROOT | |
111 | install -d $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir}} | |
112 | ||
113 | %{__make} install \ | |
114 | DESTDIR=$RPM_BUILD_ROOT | |
115 | ||
116 | cp -a client/%{name}.desktop $RPM_BUILD_ROOT%{_desktopdir}/%{name}-client.desktop | |
117 | cp -a server/%{name}-server.desktop $RPM_BUILD_ROOT%{_desktopdir} | |
118 | %{__rm} $RPM_BUILD_ROOT%{_desktopdir}/%{name}.desktop | |
119 | ||
120 | cp -a data/icons/32x32/*.png $RPM_BUILD_ROOT%{_pixmapsdir} | |
121 | cp -a data/stdsounds{,.soundspec} $RPM_BUILD_ROOT%{_datadir}/%{name} | |
122 | #cp -a freeland.tilespec $RPM_BUILD_ROOT%{_datadir}/%{name} | |
123 | #cp -a freeland $RPM_BUILD_ROOT%{_datadir}/%{name} | |
124 | ||
125 | %{__rm} -r $RPM_BUILD_ROOT%{_datadir}/locale/no | |
126 | %{__rm} $RPM_BUILD_ROOT%{_sysconfdir}/ggz.modules | |
127 | ||
128 | cp -a data/gtk_menus.xml $RPM_BUILD_ROOT%{_datadir}/%{name} | |
129 | ||
130 | %if %{with ggz_server} | |
131 | install -d $RPM_BUILD_ROOT%{_sysconfdir}/ggzd/{games,rooms} | |
132 | cp -a data/civserver.dsc $RPM_BUILD_ROOT%{_sysconfdir}/ggzd/games/civserver.dsc | |
133 | cp -a data/civserver.room $RPM_BUILD_ROOT%{_sysconfdir}/ggzd/rooms/civserver.room | |
134 | %endif | |
135 | ||
136 | %{__rm} -r $RPM_BUILD_ROOT%{_datadir}/doc/%{name} | |
137 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libfreeciv{,-srv}.{a,la} | |
138 | ||
139 | %find_lang %{name} | |
140 | ||
141 | %clean | |
142 | rm -rf $RPM_BUILD_ROOT | |
143 | ||
144 | %files -f %{name}.lang | |
145 | %defattr(644,root,root,755) | |
146 | %doc AUTHORS doc/BUGS ChangeLog doc/FAQ doc/HOWTOPLAY | |
147 | %doc NEWS NEWS-2.4 | |
148 | %doc doc/README.SDLClient doc/README.cma doc/README.effects doc/README.fcdb | |
149 | %doc doc/README.graphics doc/README.sound | |
150 | %doc doc/README.ruleset_experimental doc/README.ruleset_multiplayer doc/README.rulesets | |
151 | %doc doc/TODO | |
152 | %dir %{_datadir}/%{name} | |
153 | %{_datadir}/%{name}/helpdata.txt | |
154 | ||
155 | %files server | |
156 | %defattr(644,root,root,755) | |
157 | %attr(755,root,root) %{_bindir}/freeciv-server | |
158 | %{_desktopdir}/%{name}-server.desktop | |
159 | %{_datadir}/appdata/freeciv-server.appdata.xml | |
160 | %{_datadir}/%{name}/civ1 | |
161 | %{_datadir}/%{name}/civ2 | |
162 | %{_datadir}/%{name}/default | |
163 | %{_datadir}/%{name}/experimental | |
164 | %{_datadir}/%{name}/multiplayer | |
165 | %{_datadir}/%{name}/nation | |
166 | %{_datadir}/%{name}/scenarios | |
167 | %{_datadir}/%{name}/*.serv | |
168 | %{_mandir}/man6/freeciv-server.6* | |
169 | %{_iconsdir}/hicolor/*/apps/freeciv-server.png | |
170 | %{_pixmapsdir}/freeciv-server.png | |
171 | ||
172 | %if %{with ggz_server} | |
173 | %dir %{_sysconfdir}/ggzd | |
174 | %dir %{_sysconfdir}/ggzd/games | |
175 | %dir %{_sysconfdir}/ggzd/rooms | |
176 | %{_sysconfdir}/ggzd/games/civserver.dsc | |
177 | %{_sysconfdir}/ggzd/rooms/civserver.room | |
178 | %endif | |
179 | ||
180 | %files client | |
181 | %defattr(644,root,root,755) | |
182 | %attr(755,root,root) %{_bindir}/freeciv-gtk2 | |
183 | %attr(755,root,root) %{_bindir}/freeciv-gtk3 | |
184 | %attr(755,root,root) %{_bindir}/freeciv-sdl | |
185 | %attr(755,root,root) %{_bindir}/freeciv-stub | |
186 | %attr(755,root,root) %{_bindir}/freeciv-xaw | |
187 | %attr(755,root,root) %{_bindir}/freeciv-manual | |
188 | %attr(755,root,root) %{_bindir}/freeciv-modpack | |
189 | %{_desktopdir}/%{name}-client.desktop | |
190 | %{_desktopdir}/%{name}-gtk3.desktop | |
191 | %{_desktopdir}/%{name}-modpack.desktop | |
192 | %{_desktopdir}/%{name}-sdl.desktop | |
193 | %{_datadir}/appdata/freeciv-gtk2.appdata.xml | |
194 | %{_datadir}/appdata/freeciv-gtk3.appdata.xml | |
195 | %{_datadir}/appdata/freeciv-modpack.appdata.xml | |
196 | %{_datadir}/appdata/freeciv-sdl.appdata.xml | |
197 | %{_datadir}/%{name}/*.*spec | |
198 | %{_datadir}/%{name}/amplio2 | |
199 | %{_datadir}/%{name}/buildings | |
200 | %{_datadir}/%{name}/cimpletoon | |
201 | %{_datadir}/%{name}/flags | |
202 | %{_datadir}/%{name}/freeciv.rc* | |
203 | #%%{_datadir}/%{name}/freeland | |
204 | %{_datadir}/%{name}/gtk_menus.xml | |
205 | %{_datadir}/%{name}/hex2t | |
206 | %{_datadir}/%{name}/isophex | |
207 | %{_datadir}/%{name}/isotrident | |
208 | %{_datadir}/%{name}/misc | |
209 | %{_datadir}/%{name}/stdsounds | |
210 | %{_datadir}/%{name}/themes | |
211 | %{_datadir}/%{name}/trident | |
212 | %{_datadir}/%{name}/wonders | |
213 | %{_mandir}/man6/freeciv-client.6* | |
214 | %{_mandir}/man6/freeciv-gtk2.6* | |
215 | %{_mandir}/man6/freeciv-gtk3.6* | |
216 | %{_mandir}/man6/freeciv-manual.6* | |
217 | %{_mandir}/man6/freeciv-modpack.6* | |
218 | %{_mandir}/man6/freeciv-sdl.6* | |
219 | %{_mandir}/man6/freeciv-xaw.6* | |
220 | %{_iconsdir}/hicolor/*/apps/freeciv-client.png | |
221 | %{_iconsdir}/hicolor/*/apps/freeciv-modpack.png | |
222 | %{_pixmapsdir}/freeciv-client.png | |
223 | %{_pixmapsdir}/freeciv-modpack.png | |
224 |