1 |
commit: 38d2bc9d62e4703107619731e409093d3f0aebf4 |
2 |
Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sat Dec 28 11:53:02 2019 +0000 |
4 |
Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat Dec 28 11:53:11 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=38d2bc9d |
7 |
|
8 |
games-strategy/freeciv: Bump to version 2.5.12 and 2.6.1 |
9 |
|
10 |
Package-Manager: Portage-2.3.84, Repoman-2.3.20 |
11 |
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org> |
12 |
|
13 |
games-strategy/freeciv/Manifest | 2 + |
14 |
games-strategy/freeciv/freeciv-2.5.12.ebuild | 179 ++++++++++++++++++++++++++ |
15 |
games-strategy/freeciv/freeciv-2.6.1.ebuild | 184 +++++++++++++++++++++++++++ |
16 |
3 files changed, 365 insertions(+) |
17 |
|
18 |
diff --git a/games-strategy/freeciv/Manifest b/games-strategy/freeciv/Manifest |
19 |
index b5c5d316432..430823d3ab4 100644 |
20 |
--- a/games-strategy/freeciv/Manifest |
21 |
+++ b/games-strategy/freeciv/Manifest |
22 |
@@ -1,2 +1,4 @@ |
23 |
DIST freeciv-2.5.11.tar.bz2 40940090 BLAKE2B dfc1e714e1a3122335f555c2e57352726bda60dc0d1700b0d8ae937c85cba6beb0b2a6ffa6266b77437934ed85f1740f319c379a10c217161ee147f2339a50d3 SHA512 f5eac2fc2b7e09b9fd3b8b45145a5359f8216aef49050c692893d30584000c7db2f2a6e66ac19e67186e2653efaa0aa7656abefe2d2de25d123e9a52ce604456 |
24 |
+DIST freeciv-2.5.12.tar.bz2 40983794 BLAKE2B 53c5f9833684bef20a80c891bb001b2e03c819ba57c0989463b854fda7fe2cffe16d292e8f13f8bf8253aee0691c8ad1cb6f19522c5aae69b48165d26a0c3665 SHA512 bc0de8f2e63779ab0ac57b9a1dfd6ab30b4ad973c9ed1704ae7c1575ec63a695e65016f45abf5ad44b9d3818211aa351b74492783a4155cf19357b7f1dd2554d |
25 |
DIST freeciv-2.6.0.tar.bz2 51912466 BLAKE2B 180fa8900af6763ecae9190ce24799a77b8504d98081e48600c16c19e814b2ff1ef01ce6a41cb1a1739f848895e1551ba158f0357602f758e76b9ee6e0104a36 SHA512 658f05ed32a2045eeeadd1e12f88df927378f8032292e709af78f24c2dbc6019ba45ce67e4fe24001a9e70756c68126a313607a81e7009270ad255d7c9fe75d8 |
26 |
+DIST freeciv-2.6.1.tar.bz2 51915573 BLAKE2B 160df7f59a5d2ab8090132df5c690ee96ce6811ad0644341ba07b10000bc2e4c30ef4e60ead57d17a7d0f722e42c204d839264830c7b423ccc393b7e7b30c30b SHA512 44145eaea96d5ab4f18e843102209d0f88a626af37365cf91b5e592bcac45f2692a7e21e9b3454a3ee4b9099212f5826a4687931bb37dabbb7dedad059df1cb4 |
27 |
|
28 |
diff --git a/games-strategy/freeciv/freeciv-2.5.12.ebuild b/games-strategy/freeciv/freeciv-2.5.12.ebuild |
29 |
new file mode 100644 |
30 |
index 00000000000..bbb7332dc8e |
31 |
--- /dev/null |
32 |
+++ b/games-strategy/freeciv/freeciv-2.5.12.ebuild |
33 |
@@ -0,0 +1,179 @@ |
34 |
+# Copyright 1999-2019 Gentoo Authors |
35 |
+# Distributed under the terms of the GNU General Public License v2 |
36 |
+ |
37 |
+EAPI=6 |
38 |
+inherit autotools eutils flag-o-matic gnome2-utils |
39 |
+ |
40 |
+DESCRIPTION="multiplayer strategy game (Civilization Clone)" |
41 |
+HOMEPAGE="http://www.freeciv.org/" |
42 |
+SRC_URI="mirror://sourceforge/freeciv/${P}.tar.bz2" |
43 |
+ |
44 |
+LICENSE="GPL-2+" |
45 |
+SLOT="0" |
46 |
+KEYWORDS="~amd64 ~ppc64 ~x86" |
47 |
+IUSE="auth aimodules dedicated +gtk ipv6 mapimg modpack mysql nls qt5 readline sdl +server +sound sqlite system-lua" |
48 |
+ |
49 |
+# postgres isn't yet really supported by upstream |
50 |
+RDEPEND="app-arch/bzip2 |
51 |
+ app-arch/xz-utils |
52 |
+ net-misc/curl |
53 |
+ sys-libs/zlib |
54 |
+ auth? ( |
55 |
+ mysql? ( dev-db/mysql-connector-c:0= ) |
56 |
+ sqlite? ( dev-db/sqlite:3 ) |
57 |
+ !mysql? ( ( !sqlite? ( dev-db/mysql-connector-c:0= ) ) ) |
58 |
+ ) |
59 |
+ readline? ( sys-libs/readline:0= ) |
60 |
+ dedicated? ( aimodules? ( dev-libs/libltdl:0 ) ) |
61 |
+ !dedicated? ( |
62 |
+ media-libs/libpng:0 |
63 |
+ gtk? ( x11-libs/gtk+:2 ) |
64 |
+ mapimg? ( media-gfx/imagemagick:= ) |
65 |
+ modpack? ( x11-libs/gtk+:2 ) |
66 |
+ nls? ( virtual/libintl ) |
67 |
+ qt5? ( |
68 |
+ dev-qt/qtcore:5 |
69 |
+ dev-qt/qtgui:5 |
70 |
+ dev-qt/qtwidgets:5 |
71 |
+ ) |
72 |
+ sdl? ( |
73 |
+ media-libs/libsdl[video] |
74 |
+ media-libs/sdl-gfx |
75 |
+ media-libs/sdl-image[png] |
76 |
+ media-libs/sdl-ttf |
77 |
+ ) |
78 |
+ server? ( aimodules? ( sys-devel/libtool:2 ) ) |
79 |
+ sound? ( |
80 |
+ media-libs/libsdl[sound] |
81 |
+ media-libs/sdl-mixer[vorbis] |
82 |
+ ) |
83 |
+ !sdl? ( !gtk? ( x11-libs/gtk+:2 ) ) |
84 |
+ ) |
85 |
+ system-lua? ( >=dev-lang/lua-5.2 )" |
86 |
+DEPEND="${RDEPEND} |
87 |
+ virtual/pkgconfig |
88 |
+ !dedicated? ( |
89 |
+ x11-base/xorg-proto |
90 |
+ nls? ( sys-devel/gettext ) |
91 |
+ )" |
92 |
+ |
93 |
+pkg_setup() { |
94 |
+ if use !dedicated && use !server ; then |
95 |
+ ewarn "Disabling server USE flag will make it impossible" |
96 |
+ ewarn "to start local games, but you will still be able to" |
97 |
+ ewarn "join multiplayer games." |
98 |
+ fi |
99 |
+} |
100 |
+ |
101 |
+src_prepare() { |
102 |
+ default |
103 |
+ |
104 |
+ eautoreconf |
105 |
+ |
106 |
+ # install the .desktop in /usr/share/applications |
107 |
+ # install the icons in /usr/share/pixmaps |
108 |
+ sed -i \ |
109 |
+ -e 's:^.*\(desktopfiledir = \).*:\1/usr/share/applications:' \ |
110 |
+ -e 's:^\(icon[0-9]*dir = \)$(prefix)\(.*\):\1/usr\2:' \ |
111 |
+ -e 's:^\(icon[0-9]*dir = \)$(datadir)\(.*\):\1/usr/share\2:' \ |
112 |
+ client/Makefile.in \ |
113 |
+ server/Makefile.in \ |
114 |
+ tools/Makefile.in \ |
115 |
+ data/icons/Makefile.in || die |
116 |
+ sed -i -e 's/=SDL/=X-SDL/' bootstrap/freeciv-sdl.desktop.in || die |
117 |
+} |
118 |
+ |
119 |
+src_configure() { |
120 |
+ local myclient mydatabase myeconfargs |
121 |
+ |
122 |
+ if use auth ; then |
123 |
+ if ! use mysql && ! use sqlite ; then |
124 |
+ einfo "No database backend chosen, defaulting" |
125 |
+ einfo "to mysql!" |
126 |
+ mydatabase=mysql |
127 |
+ else |
128 |
+ use mysql && mydatabase+=" mysql" |
129 |
+ use sqlite && mydatabase+=" sqlite3" |
130 |
+ fi |
131 |
+ else |
132 |
+ mydatabase=no |
133 |
+ fi |
134 |
+ |
135 |
+ if use dedicated ; then |
136 |
+ myclient="no" |
137 |
+ myeconfargs+=( --enable-server ) |
138 |
+ else |
139 |
+ if use !sdl && use !gtk && ! use qt5 ; then |
140 |
+ einfo "No client backend given, defaulting to" |
141 |
+ einfo "gtk2 client!" |
142 |
+ myclient="gtk2" |
143 |
+ else |
144 |
+ use sdl && myclient+=" sdl" |
145 |
+ use gtk && myclient+=" gtk2" |
146 |
+ if use qt5 ; then |
147 |
+ myclient+=" qt" |
148 |
+ append-cxxflags -std=c++11 |
149 |
+ fi |
150 |
+ fi |
151 |
+ myeconfargs+=( $(use_enable server) --without-ggz-client ) |
152 |
+ fi |
153 |
+ |
154 |
+ myeconfargs+=( |
155 |
+ --enable-aimodules="$(usex aimodules "yes" "no")" |
156 |
+ --enable-client="${myclient}" |
157 |
+ --enable-fcdb="${mydatabase}" |
158 |
+ --enable-fcmp="$(usex modpack "gtk2" "no")" |
159 |
+ # disabling shared libs will break aimodules USE flag |
160 |
+ --enable-shared |
161 |
+ --localedir=/usr/share/locale |
162 |
+ $(use_enable ipv6) |
163 |
+ $(use_enable mapimg) |
164 |
+ $(use_enable nls) |
165 |
+ $(use_enable sound sdl-mixer) |
166 |
+ $(use_enable system-lua sys-lua) |
167 |
+ $(use_with readline) |
168 |
+ ) |
169 |
+ econf "${myeconfargs[@]}" |
170 |
+} |
171 |
+ |
172 |
+src_install() { |
173 |
+ default |
174 |
+ |
175 |
+ if use dedicated ; then |
176 |
+ rm -rf "${ED%/}/usr/share/pixmaps" |
177 |
+ rm -f "${ED%/}"/usr/share/man/man6/freeciv-{client,gtk2,gtk3,modpack,qt,sdl,xaw}* |
178 |
+ else |
179 |
+ if use server ; then |
180 |
+ # Create and install the html manual. It can't be done for dedicated |
181 |
+ # servers, because the 'freeciv-manual' tool is then not built. Also |
182 |
+ # delete freeciv-manual from the GAMES_BINDIR, because it's useless. |
183 |
+ # Note: to have it localized, it should be ran from _postinst, or |
184 |
+ # something like that, but then it's a PITA to avoid orphan files... |
185 |
+ ./tools/freeciv-manual || die |
186 |
+ docinto html |
187 |
+ dodoc manual*.html |
188 |
+ fi |
189 |
+ if use sdl ; then |
190 |
+ make_desktop_entry freeciv-sdl "Freeciv (SDL)" freeciv-client |
191 |
+ else |
192 |
+ rm -f "${ED%/}"/usr/share/man/man6/freeciv-sdl* |
193 |
+ fi |
194 |
+ rm -f "${ED%/}"/usr/share/man/man6/freeciv-xaw* |
195 |
+ fi |
196 |
+ find "${ED}" -name "freeciv-manual*" -delete |
197 |
+ |
198 |
+ rm -f "${ED%/}/usr/$(get_libdir)"/*.a |
199 |
+ prune_libtool_files |
200 |
+} |
201 |
+ |
202 |
+pkg_preinst() { |
203 |
+ gnome2_icon_savelist |
204 |
+} |
205 |
+ |
206 |
+pkg_postinst() { |
207 |
+ gnome2_icon_cache_update |
208 |
+} |
209 |
+ |
210 |
+pkg_postrm() { |
211 |
+ gnome2_icon_cache_update |
212 |
+} |
213 |
|
214 |
diff --git a/games-strategy/freeciv/freeciv-2.6.1.ebuild b/games-strategy/freeciv/freeciv-2.6.1.ebuild |
215 |
new file mode 100644 |
216 |
index 00000000000..764443f246c |
217 |
--- /dev/null |
218 |
+++ b/games-strategy/freeciv/freeciv-2.6.1.ebuild |
219 |
@@ -0,0 +1,184 @@ |
220 |
+# Copyright 1999-2019 Gentoo Authors |
221 |
+# Distributed under the terms of the GNU General Public License v2 |
222 |
+ |
223 |
+EAPI=7 |
224 |
+ |
225 |
+MY_PV="${PV/_beta/-beta}" |
226 |
+MY_PV="${MY_PV/_rc/-RC}" |
227 |
+MY_P="${PN}-${MY_PV}" |
228 |
+inherit desktop flag-o-matic xdg |
229 |
+ |
230 |
+DESCRIPTION="multiplayer strategy game (Civilization Clone)" |
231 |
+HOMEPAGE="http://www.freeciv.org/" |
232 |
+ |
233 |
+if [[ ${PV} != *_beta* ]] && [[ ${PV} != *_rc* ]] ; then |
234 |
+ SRC_URI="mirror://sourceforge/freeciv/${MY_P}.tar.bz2" |
235 |
+ KEYWORDS="~amd64 ~x86" |
236 |
+fi |
237 |
+ |
238 |
+LICENSE="GPL-2+" |
239 |
+SLOT="0" |
240 |
+IUSE="aimodules auth dedicated +gtk ipv6 mapimg modpack mysql nls qt5 readline sdl +server +sound sqlite system-lua" |
241 |
+ |
242 |
+# postgres isn't yet really supported by upstream |
243 |
+BDEPEND=" |
244 |
+ virtual/pkgconfig |
245 |
+ !dedicated? ( |
246 |
+ x11-base/xorg-proto |
247 |
+ nls? ( sys-devel/gettext ) |
248 |
+ ) |
249 |
+" |
250 |
+DEPEND=" |
251 |
+ app-arch/bzip2 |
252 |
+ app-arch/xz-utils |
253 |
+ net-misc/curl |
254 |
+ sys-libs/zlib |
255 |
+ auth? ( |
256 |
+ !mysql? ( ( !sqlite? ( dev-db/mysql-connector-c:0= ) ) ) |
257 |
+ mysql? ( dev-db/mysql-connector-c:0= ) |
258 |
+ sqlite? ( dev-db/sqlite:3 ) |
259 |
+ ) |
260 |
+ dedicated? ( aimodules? ( dev-libs/libltdl:0 ) ) |
261 |
+ !dedicated? ( |
262 |
+ media-libs/libpng:0 |
263 |
+ gtk? ( x11-libs/gtk+:2 ) |
264 |
+ mapimg? ( media-gfx/imagemagick:= ) |
265 |
+ modpack? ( x11-libs/gtk+:2 ) |
266 |
+ nls? ( virtual/libintl ) |
267 |
+ qt5? ( |
268 |
+ dev-qt/qtcore:5 |
269 |
+ dev-qt/qtgui:5 |
270 |
+ dev-qt/qtwidgets:5 |
271 |
+ ) |
272 |
+ !sdl? ( !gtk? ( x11-libs/gtk+:2 ) ) |
273 |
+ sdl? ( |
274 |
+ media-libs/libsdl2[video] |
275 |
+ media-libs/sdl2-gfx |
276 |
+ media-libs/sdl2-image[png] |
277 |
+ media-libs/sdl2-ttf |
278 |
+ ) |
279 |
+ server? ( aimodules? ( sys-devel/libtool:2 ) ) |
280 |
+ sound? ( |
281 |
+ media-libs/libsdl2[sound] |
282 |
+ media-libs/sdl2-mixer[vorbis] |
283 |
+ ) |
284 |
+ ) |
285 |
+ readline? ( sys-libs/readline:0= ) |
286 |
+ system-lua? ( >=dev-lang/lua-5.3:= ) |
287 |
+" |
288 |
+RDEPEND="${DEPEND}" |
289 |
+ |
290 |
+S="${WORKDIR}/${MY_P}" |
291 |
+ |
292 |
+pkg_setup() { |
293 |
+ if use !dedicated && use !server ; then |
294 |
+ ewarn "Disabling server USE flag will make it impossible" |
295 |
+ ewarn "to start local games, but you will still be able to" |
296 |
+ ewarn "join multiplayer games." |
297 |
+ fi |
298 |
+} |
299 |
+ |
300 |
+src_prepare() { |
301 |
+ default |
302 |
+ |
303 |
+ # install the .desktop in /usr/share/applications |
304 |
+ # install the icons in /usr/share/pixmaps |
305 |
+ sed -i \ |
306 |
+ -e 's:^.*\(desktopfiledir = \).*:\1/usr/share/applications:' \ |
307 |
+ -e 's:^\(icon[0-9]*dir = \)$(prefix)\(.*\):\1/usr\2:' \ |
308 |
+ -e 's:^\(icon[0-9]*dir = \)$(datadir)\(.*\):\1/usr/share\2:' \ |
309 |
+ client/Makefile.in \ |
310 |
+ server/Makefile.in \ |
311 |
+ tools/Makefile.in \ |
312 |
+ data/icons/Makefile.in || die |
313 |
+ sed -i -e 's/=SDL/=X-SDL/' bootstrap/freeciv-sdl.desktop.in || die |
314 |
+} |
315 |
+ |
316 |
+src_configure() { |
317 |
+ local myclient=() mydatabase=() myeconfargs=() |
318 |
+ |
319 |
+ if use auth ; then |
320 |
+ if ! use mysql && ! use sqlite ; then |
321 |
+ einfo "No database backend chosen, defaulting" |
322 |
+ einfo "to mysql!" |
323 |
+ mydatabase=( mysql ) |
324 |
+ else |
325 |
+ use mysql && mydatabase+=( mysql ) |
326 |
+ use sqlite && mydatabase+=( sqlite3 ) |
327 |
+ fi |
328 |
+ else |
329 |
+ mydatabase=( no ) |
330 |
+ fi |
331 |
+ |
332 |
+ if use dedicated ; then |
333 |
+ myclient=( no ) |
334 |
+ myeconfargs+=( |
335 |
+ --enable-server |
336 |
+ --enable-freeciv-manual=html |
337 |
+ ) |
338 |
+ else |
339 |
+ if use !sdl && use !gtk && ! use qt5 ; then |
340 |
+ einfo "No client backend given, defaulting to" |
341 |
+ einfo "gtk2 client!" |
342 |
+ myclient=( gtk2 ) |
343 |
+ else |
344 |
+ use sdl && myclient+=( sdl2 ) |
345 |
+ use gtk && myclient+=( gtk2 ) |
346 |
+ if use qt5 ; then |
347 |
+ myclient+=( qt ) |
348 |
+ append-cxxflags -std=c++11 |
349 |
+ fi |
350 |
+ fi |
351 |
+ myeconfargs+=( |
352 |
+ $(use_enable server) |
353 |
+ $(use_enable server freeciv-manual html ) |
354 |
+ ) |
355 |
+ fi |
356 |
+ |
357 |
+ myeconfargs+=( |
358 |
+ --enable-aimodules="$(usex aimodules "yes" "no")" |
359 |
+ --enable-client="${myclient[*]}" |
360 |
+ --enable-fcdb="${mydatabase[*]}" |
361 |
+ --enable-fcmp="$(usex modpack "gtk2" "no")" |
362 |
+ # disabling shared libs will break aimodules USE flag |
363 |
+ --enable-shared |
364 |
+ --localedir=/usr/share/locale |
365 |
+ $(use_enable ipv6) |
366 |
+ $(use_enable mapimg) |
367 |
+ $(use_enable nls) |
368 |
+ $(use_enable sound sdl-mixer) |
369 |
+ $(use_enable system-lua sys-lua) |
370 |
+ $(use_with readline) |
371 |
+ ) |
372 |
+ econf "${myeconfargs[@]}" |
373 |
+} |
374 |
+ |
375 |
+src_install() { |
376 |
+ default |
377 |
+ |
378 |
+ if use dedicated ; then |
379 |
+ rm -rf "${ED}"/usr/share/pixmaps |
380 |
+ rm -f "${ED}"/usr/share/man/man6/freeciv-{client,gtk2,gtk3,modpack,qt,sdl,xaw}* |
381 |
+ else |
382 |
+ if use server ; then |
383 |
+ # Create and install the html manual. It can't be done for dedicated |
384 |
+ # servers, because the 'freeciv-manual' tool is then not built. Also |
385 |
+ # delete freeciv-manual from the GAMES_BINDIR, because it's useless. |
386 |
+ # Note: to have it localized, it should be ran from _postinst, or |
387 |
+ # something like that, but then it's a PITA to avoid orphan files... |
388 |
+ ./tools/freeciv-manual || die |
389 |
+ docinto html |
390 |
+ dodoc classic*.html |
391 |
+ fi |
392 |
+ if use sdl ; then |
393 |
+ make_desktop_entry freeciv-sdl "Freeciv (SDL)" freeciv-client |
394 |
+ else |
395 |
+ rm -f "${ED}"/usr/share/man/man6/freeciv-sdl* |
396 |
+ fi |
397 |
+ rm -f "${ED}"/usr/share/man/man6/freeciv-xaw* |
398 |
+ fi |
399 |
+ find "${ED}" -name "freeciv-manual*" -delete |
400 |
+ |
401 |
+ rm -f "${ED}/usr/$(get_libdir)"/*.a |
402 |
+ find "${ED}" -name "*.la" -delete || die |
403 |
+} |