1 |
commit: 605a5085912f1fad31a123d39449baf942a36dd7 |
2 |
Author: Gilles Dartiguelongue <eva <AT> gentoo <DOT> org> |
3 |
AuthorDate: Tue Dec 25 21:33:51 2012 +0000 |
4 |
Commit: Gilles Dartiguelongue <eva <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Dec 25 21:33:51 2012 +0000 |
6 |
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/gnome.git;a=commit;h=605a5085 |
7 |
|
8 |
gnome-extra/gnome-games: moved to gx86 |
9 |
|
10 |
* Sync live ebuild with gx86 changes. |
11 |
* Drop unused USE=seed from metadata.xml. |
12 |
|
13 |
--- |
14 |
gnome-extra/gnome-games/gnome-games-3.6.1.ebuild | 156 ---------------------- |
15 |
gnome-extra/gnome-games/gnome-games-9999.ebuild | 73 ++++++++--- |
16 |
gnome-extra/gnome-games/metadata.xml | 2 - |
17 |
3 files changed, 54 insertions(+), 177 deletions(-) |
18 |
|
19 |
diff --git a/gnome-extra/gnome-games/gnome-games-3.6.1.ebuild b/gnome-extra/gnome-games/gnome-games-3.6.1.ebuild |
20 |
deleted file mode 100644 |
21 |
index 6813cef..0000000 |
22 |
--- a/gnome-extra/gnome-games/gnome-games-3.6.1.ebuild |
23 |
+++ /dev/null |
24 |
@@ -1,156 +0,0 @@ |
25 |
-# Copyright 1999-2012 Gentoo Foundation |
26 |
-# Distributed under the terms of the GNU General Public License v2 |
27 |
-# $Header: $ |
28 |
- |
29 |
-EAPI="4" |
30 |
-GCONF_DEBUG="no" |
31 |
-GNOME2_LA_PUNT="yes" |
32 |
-PYTHON_DEPEND="2:2.5" |
33 |
-PYTHON_USE_WITH="xml" |
34 |
- |
35 |
-# Make sure games is inherited first so that the gnome2 |
36 |
-# functions will be called if they are not overridden |
37 |
-inherit games gnome2 python virtualx |
38 |
- |
39 |
-DESCRIPTION="Collection of games for the GNOME desktop" |
40 |
-HOMEPAGE="http://live.gnome.org/GnomeGames/" |
41 |
- |
42 |
-LICENSE="GPL-2 GPL-3 FDL-1.1" |
43 |
-SLOT="0" |
44 |
-# TODO: file KEYWORDREQ bug once it's determined that seed is usable |
45 |
-KEYWORDS="~amd64 ~mips ~x86" |
46 |
- |
47 |
-# FIXME: we should decide whether to have USE flag for games of features |
48 |
-# IUSE="artworkextra clutter opengl python test" |
49 |
-# vs |
50 |
-# IUSE="artworkextra aisleriot glchess quadrapassel swell-foop lightsoff gnibbles sudoku" |
51 |
-IUSE="artworkextra +aisleriot +clutter +glchess +sudoku test" |
52 |
- |
53 |
-COMMON_DEPEND=" |
54 |
- >=dev-libs/glib-2.25.7 |
55 |
- >=gnome-base/librsvg-2.32 |
56 |
- >=x11-libs/cairo-1.10 |
57 |
- >=x11-libs/gtk+-3.3.11:3[introspection] |
58 |
- |
59 |
- >=media-libs/libcanberra-0.26[gtk3] |
60 |
- |
61 |
- artworkextra? ( >=gnome-extra/gnome-games-extra-data-3 ) |
62 |
- clutter? ( |
63 |
- media-libs/clutter:1.0[introspection] |
64 |
- >=media-libs/clutter-gtk-0.91.6:1.0 ) |
65 |
- glchess? ( |
66 |
- dev-db/sqlite:3 |
67 |
- virtual/glu |
68 |
- virtual/opengl |
69 |
- x11-libs/libX11 ) |
70 |
- sudoku? ( dev-libs/gobject-introspection ) |
71 |
-" |
72 |
-RDEPEND="${COMMON_DEPEND} |
73 |
- sudoku? ( |
74 |
- dev-python/pycairo |
75 |
- dev-python/pygobject:3[cairo] |
76 |
- x11-libs/gdk-pixbuf:2[introspection] |
77 |
- x11-libs/pango[introspection] |
78 |
- >=x11-libs/gtk+-3.0.0:3[introspection] ) |
79 |
- |
80 |
- !<gnome-extra/gnome-games-extra-data-3 |
81 |
-" |
82 |
-DEPEND="${COMMON_DEPEND} |
83 |
- app-text/yelp-tools |
84 |
- >=dev-util/intltool-0.40.4 |
85 |
- dev-util/itstool |
86 |
- >=sys-devel/gettext-0.10.40 |
87 |
- virtual/pkgconfig |
88 |
-" |
89 |
- |
90 |
-# For compatibility with older versions of the gnome-games package |
91 |
-PDEPEND="aisleriot? ( games-board/aisleriot )" |
92 |
- |
93 |
-# Others are installed below; multiples in this package. |
94 |
-DOCS="AUTHORS HACKING MAINTAINERS TODO" |
95 |
- |
96 |
-_omitgame() { |
97 |
- G2CONF="${G2CONF},${1}" |
98 |
-} |
99 |
- |
100 |
-pkg_setup() { |
101 |
- # create the games user / group |
102 |
- games_pkg_setup |
103 |
- |
104 |
- python_set_active_version 2 |
105 |
- python_pkg_setup |
106 |
-} |
107 |
- |
108 |
-src_prepare() { |
109 |
- G2CONF="${G2CONF} |
110 |
- --disable-static |
111 |
- ITSTOOL=$(type -P true) |
112 |
- VALAC=$(type -P true) |
113 |
- --with-platform=gnome |
114 |
- --with-scores-group=${GAMES_GROUP} |
115 |
- --enable-omitgames=none" # This line should be last for _omitgame |
116 |
- |
117 |
- # FIXME: Use REQUIRED_USE once games.eclass is ported to EAPI 4 |
118 |
- if ! use clutter; then |
119 |
- ewarn "USE='-clutter' => quadrapassel, swell-foop, lightsoff, gnibbles won't be installed" |
120 |
- _omitgame quadrapassel |
121 |
- _omitgame gnibbles |
122 |
- _omitgame swell-foop |
123 |
- _omitgame lightsoff |
124 |
- fi |
125 |
- |
126 |
- if ! use glchess; then |
127 |
- _omitgame glchess |
128 |
- fi |
129 |
- |
130 |
- if ! use sudoku; then |
131 |
- _omitgame gnome-sudoku |
132 |
- else |
133 |
- python_convert_shebangs -r 2 gnome-sudoku/src |
134 |
- python_clean_py-compile_files |
135 |
- fi |
136 |
- |
137 |
- gnome2_src_prepare |
138 |
-} |
139 |
- |
140 |
-src_test() { |
141 |
- Xemake check || die "tests failed" |
142 |
-} |
143 |
- |
144 |
-src_install() { |
145 |
- gnome2_src_install |
146 |
- |
147 |
- # Documentation install for each of the games |
148 |
- for game in \ |
149 |
- $(find . -maxdepth 1 -type d ! -name po ! -name libgames-support); do |
150 |
- docinto ${game} |
151 |
- for doc in AUTHORS ChangeLog NEWS README TODO; do |
152 |
- [ -s ${game}/${doc} ] && dodoc ${game}/${doc} |
153 |
- done |
154 |
- done |
155 |
-} |
156 |
- |
157 |
-pkg_preinst() { |
158 |
- gnome2_pkg_preinst |
159 |
- # Avoid overwriting previous .scores files |
160 |
- local basefile |
161 |
- for scorefile in "${ED}"/var/lib/games/*.scores; do |
162 |
- basefile=$(basename $scorefile) |
163 |
- if [ -s "${EROOT}/var/lib/games/${basefile}" ]; then |
164 |
- cp "${EROOT}/var/lib/games/${basefile}" \ |
165 |
- "${ED}/var/lib/games/${basefile}" |
166 |
- fi |
167 |
- done |
168 |
-} |
169 |
- |
170 |
-pkg_postinst() { |
171 |
- games_pkg_postinst |
172 |
- gnome2_pkg_postinst |
173 |
- python_need_rebuild |
174 |
- use sudoku && python_mod_optimize gnome_sudoku |
175 |
-} |
176 |
- |
177 |
-pkg_postrm() { |
178 |
- gnome2_pkg_postrm |
179 |
- python_mod_cleanup gnome_sudoku |
180 |
-} |
181 |
|
182 |
diff --git a/gnome-extra/gnome-games/gnome-games-9999.ebuild b/gnome-extra/gnome-games/gnome-games-9999.ebuild |
183 |
index 81d8d5b..b3a4e57 100644 |
184 |
--- a/gnome-extra/gnome-games/gnome-games-9999.ebuild |
185 |
+++ b/gnome-extra/gnome-games/gnome-games-9999.ebuild |
186 |
@@ -2,15 +2,15 @@ |
187 |
# Distributed under the terms of the GNU General Public License v2 |
188 |
# $Header: $ |
189 |
|
190 |
-EAPI="4" |
191 |
+EAPI="5" |
192 |
GCONF_DEBUG="no" |
193 |
GNOME2_LA_PUNT="yes" |
194 |
-PYTHON_DEPEND="2:2.5" |
195 |
-PYTHON_USE_WITH="xml" |
196 |
+PYTHON_COMPAT=( python2_{6,7} ) |
197 |
+PYTHON_REQ_USE="xml" |
198 |
|
199 |
# Make sure games is inherited first so that the gnome2 |
200 |
# functions will be called if they are not overridden |
201 |
-inherit games gnome2 python virtualx |
202 |
+inherit games gnome2 python-r1 virtualx |
203 |
if [[ ${PV} = 9999 ]]; then |
204 |
inherit gnome2-live |
205 |
fi |
206 |
@@ -24,8 +24,12 @@ SLOT="0" |
207 |
if [[ ${PV} = 9999 ]]; then |
208 |
KEYWORDS="" |
209 |
else |
210 |
- KEYWORDS="~amd64 ~x86" |
211 |
+ KEYWORDS="~amd64 ~mips ~x86" |
212 |
fi |
213 |
+# FIXME: we should decide whether to have USE flag for games or features |
214 |
+# IUSE="artworkextra clutter opengl python test" |
215 |
+# vs |
216 |
+# IUSE="artworkextra aisleriot glchess quadrapassel swell-foop lightsoff gnibbles sudoku" |
217 |
IUSE="artworkextra +aisleriot +clutter +glchess +sudoku test" |
218 |
|
219 |
COMMON_DEPEND=" |
220 |
@@ -49,16 +53,16 @@ COMMON_DEPEND=" |
221 |
" |
222 |
RDEPEND="${COMMON_DEPEND} |
223 |
sudoku? ( |
224 |
+ ${PYTHON_DEPS} |
225 |
dev-python/pycairo |
226 |
- dev-python/pygobject:3[cairo] |
227 |
+ dev-python/pygobject:3[cairo,${PYTHON_USEDEP}] |
228 |
x11-libs/gdk-pixbuf:2[introspection] |
229 |
x11-libs/pango[introspection] |
230 |
- >=x11-libs/gtk+-3.0.0:3[introspection] ) |
231 |
+ >=x11-libs/gtk+-3:3[introspection] ) |
232 |
|
233 |
!<gnome-extra/gnome-games-extra-data-3 |
234 |
" |
235 |
DEPEND="${COMMON_DEPEND} |
236 |
- app-text/yelp-tools |
237 |
>=dev-util/intltool-0.40.4 |
238 |
dev-util/itstool |
239 |
>=sys-devel/gettext-0.10.40 |
240 |
@@ -67,6 +71,7 @@ DEPEND="${COMMON_DEPEND} |
241 |
|
242 |
if [[ ${PV} = 9999 ]]; then |
243 |
DEPEND="${COMMON_DEPEND} |
244 |
+ app-text/yelp-tools |
245 |
>=dev-lang/vala-0.15.1:0.16" |
246 |
fi |
247 |
|
248 |
@@ -83,15 +88,19 @@ _omitgame() { |
249 |
pkg_setup() { |
250 |
# create the games user / group |
251 |
games_pkg_setup |
252 |
- |
253 |
- python_set_active_version 2 |
254 |
python_pkg_setup |
255 |
} |
256 |
|
257 |
src_prepare() { |
258 |
+ gnome2_src_prepare |
259 |
+ if use sudoku ; then |
260 |
+ python_copy_sources |
261 |
+ fi |
262 |
+} |
263 |
+ |
264 |
+src_configure() { |
265 |
G2CONF="${G2CONF} |
266 |
--disable-static |
267 |
- ITSTOOL=$(type -P true) |
268 |
VALAC=$(type -P true) |
269 |
--with-platform=gnome |
270 |
--with-scores-group=${GAMES_GROUP} |
271 |
@@ -112,20 +121,43 @@ src_prepare() { |
272 |
|
273 |
if ! use sudoku; then |
274 |
_omitgame gnome-sudoku |
275 |
+ fi |
276 |
+ |
277 |
+ [[ ${PV} != 9999 ]] && G2CONF="${G2CONF} ITSTOOL=$(type -P true)" |
278 |
+ |
279 |
+ if use sudoku ; then |
280 |
+ python_foreach_impl run_in_build_dir gnome2_src_configure |
281 |
else |
282 |
- python_convert_shebangs -r 2 gnome-sudoku/src |
283 |
- python_clean_py-compile_files |
284 |
+ gnome2_src_configure |
285 |
fi |
286 |
+} |
287 |
|
288 |
- gnome2_src_prepare |
289 |
+src_compile() { |
290 |
+ if use sudoku ; then |
291 |
+ python_foreach_impl run_in_build_dir gnome2_src_compile |
292 |
+ else |
293 |
+ gnome2_src_compile |
294 |
+ fi |
295 |
} |
296 |
|
297 |
src_test() { |
298 |
- Xemake check || die "tests failed" |
299 |
+ if use sudoku ; then |
300 |
+ python_foreach_impl run_in_build_dir Xemake check |
301 |
+ else |
302 |
+ Xemake check || die "tests failed" |
303 |
+ fi |
304 |
} |
305 |
|
306 |
src_install() { |
307 |
- gnome2_src_install |
308 |
+ if use sudoku ; then |
309 |
+ install_python() { |
310 |
+ gnome2_src_install |
311 |
+ python_doscript gnome-sudoku/src/gnome-sudoku |
312 |
+ } |
313 |
+ python_foreach_impl run_in_build_dir install_python |
314 |
+ else |
315 |
+ gnome2_src_install |
316 |
+ fi |
317 |
|
318 |
# Documentation install for each of the games |
319 |
for game in \ |
320 |
@@ -153,11 +185,14 @@ pkg_preinst() { |
321 |
pkg_postinst() { |
322 |
games_pkg_postinst |
323 |
gnome2_pkg_postinst |
324 |
- python_need_rebuild |
325 |
- use sudoku && python_mod_optimize gnome_sudoku |
326 |
} |
327 |
|
328 |
pkg_postrm() { |
329 |
gnome2_pkg_postrm |
330 |
- python_mod_cleanup gnome_sudoku |
331 |
+} |
332 |
+ |
333 |
+run_in_build_dir() { |
334 |
+ pushd "${BUILD_DIR}" > /dev/null || die |
335 |
+ "$@" |
336 |
+ popd > /dev/null |
337 |
} |
338 |
|
339 |
diff --git a/gnome-extra/gnome-games/metadata.xml b/gnome-extra/gnome-games/metadata.xml |
340 |
index ac06171..149899a 100644 |
341 |
--- a/gnome-extra/gnome-games/metadata.xml |
342 |
+++ b/gnome-extra/gnome-games/metadata.xml |
343 |
@@ -8,8 +8,6 @@ |
344 |
<flag name="clutter">Install games that use <pkg>media-libs/clutter</pkg></flag> |
345 |
<flag name="glchess">Install Chess written in <pkg>dev-lang/vala</pkg> and |
346 |
OpenGL</flag> |
347 |
- <flag name="seed">Install swell-foop and lightsoff which are written in |
348 |
- JavaScript using <pkg>dev-libs/seed</pkg></flag> |
349 |
<flag name="sudoku">Install the game Sudoku which uses |
350 |
<pkg>dev-python/pygobject</pkg> and introspection</flag> |
351 |
</use> |