Gentoo Archives: gentoo-commits

From: Austin English <wizardedit@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: games-sports/xmoto/
Date: Thu, 29 Sep 2016 23:27:05
Message-Id: 1475187680.774b7861067cea49bb9412415b6fed077f6a9d7f.wizardedit@gentoo
1 commit: 774b7861067cea49bb9412415b6fed077f6a9d7f
2 Author: Austin English <wizardedit <AT> gentoo <DOT> org>
3 AuthorDate: Thu Sep 29 22:21:20 2016 +0000
4 Commit: Austin English <wizardedit <AT> gentoo <DOT> org>
5 CommitDate: Thu Sep 29 22:21:20 2016 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=774b7861
7
8 games-sports/xmoto: remove deprecated games eclass
9
10 Also update to EAPI 6
11
12 Gentoo-Bug: https://bugs.gentoo.org/574082
13
14 Package-Manager: portage-2.3.0
15
16 games-sports/xmoto/xmoto-0.5.11-r1.ebuild | 97 +++++++++++++++++++++++++++++++
17 1 file changed, 97 insertions(+)
18
19 diff --git a/games-sports/xmoto/xmoto-0.5.11-r1.ebuild b/games-sports/xmoto/xmoto-0.5.11-r1.ebuild
20 new file mode 100644
21 index 00000000..d5cab7b
22 --- /dev/null
23 +++ b/games-sports/xmoto/xmoto-0.5.11-r1.ebuild
24 @@ -0,0 +1,97 @@
25 +# Copyright 1999-2016 Gentoo Foundation
26 +# Distributed under the terms of the GNU General Public License v2
27 +# $Id$
28 +
29 +EAPI=6
30 +inherit autotools eutils flag-o-matic
31 +
32 +LVL_PV="0.7.0" #they unfortunately don't release both at the same time, why ~ as separator :(
33 +LVL="inksmoto-${LVL_PV}"
34 +DEB_PV=6
35 +DESCRIPTION="A challenging 2D motocross platform game"
36 +HOMEPAGE="http://xmoto.tuxfamily.org"
37 +SRC_URI="http://download.tuxfamily.org/xmoto/xmoto/${PV}/${P}-src.tar.gz
38 + mirror://debian/pool/main/x/${PN}/${PN}_${PV}+dfsg-${DEB_PV}.debian.tar.xz
39 + editor? ( http://download.tuxfamily.org/xmoto/svg2lvl/${LVL_PV}/${LVL}.tar.gz )"
40 +
41 +LICENSE="GPL-2"
42 +SLOT="0"
43 +KEYWORDS="~amd64 ~ppc ~x86"
44 +IUSE="editor nls"
45 +
46 +RDEPEND="
47 + app-arch/bzip2
48 + dev-db/sqlite:3
49 + dev-games/ode
50 + dev-lang/lua:0[deprecated]
51 + dev-libs/libxdg-basedir
52 + dev-libs/libxml2
53 + media-fonts/dejavu
54 + media-libs/libpng:0
55 + media-libs/libsdl[joystick,opengl]
56 + media-libs/sdl-mixer[vorbis]
57 + media-libs/sdl-net
58 + media-libs/sdl-ttf
59 + net-misc/curl
60 + virtual/jpeg:0
61 + virtual/opengl
62 + virtual/glu
63 + nls? ( virtual/libintl )"
64 +DEPEND="${RDEPEND}
65 + app-arch/xz-utils
66 + nls? ( sys-devel/gettext )"
67 +RDEPEND="${RDEPEND}
68 + editor? ( media-gfx/inkscape )"
69 +
70 +src_prepare() {
71 + default
72 +
73 + EPATCH_SOURCE="${WORKDIR}/debian/patches" \
74 + epatch $(cat ${WORKDIR}/debian/patches/series)
75 + use editor && rm -vf "${WORKDIR}"/extensions/{bezmisc,inkex}.py
76 + sed -i \
77 + -e '/^gettextsrcdir/s:=.*:= @localedir@/gettext/po:' \
78 + po/Makefile.in.in || die
79 + mv configure.{in,ac} || die
80 + eautoreconf
81 +}
82 +
83 +src_configure() {
84 + # bug #289792
85 + filter-flags -DdDOUBLE -DdSINGLE
86 +
87 + # bug #569624 - ode-0.13 needs one or the other defined
88 + append-cppflags -Dd$(has_version 'dev-games/ode[double-precision]' && echo DOUBLE || echo SINGLE)
89 +
90 + econf \
91 + --enable-threads=posix \
92 + $(use_enable nls) \
93 + --localedir=/usr/share/locale \
94 + --with-localesdir=/usr/share/locale \
95 + --with-renderer-sdlGfx=0 \
96 + --with-renderer-openGl=1
97 +}
98 +
99 +src_install() {
100 + default
101 +
102 + rm -f "${D}/usr/share/xmoto"/Textures/Fonts/DejaVu*.ttf
103 + dosym /usr/share/fonts/dejavu/DejaVuSans.ttf /usr/share/xmoto/Textures/Fonts/DejaVuSans.ttf
104 + dosym /usr/share/fonts/dejavu/DejaVuSansMono.ttf /usr/share/xmoto/Textures/Fonts/DejaVuSansMono.ttf
105 + doicon extra/xmoto.xpm
106 + make_desktop_entry xmoto Xmoto
107 +
108 + if use editor; then
109 + insinto /usr/share/inkscape/
110 + doins -r "${WORKDIR}"/extensions/
111 + fi
112 +}
113 +
114 +pkg_postinst() {
115 + if use editor; then
116 + elog "If you want to know how to create Xmoto levels"
117 + elog "have a look at this Tutorial:"
118 + elog " http://wiki.xmoto.tuxfamily.org/index.php?title=Inksmoto-${LVL_PV}"
119 + elog "You can share your levels on the Xmoto homepage."
120 + fi
121 +}