forked from gentoo/gentoo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
tuxmath-2.0.3.ebuild
67 lines (56 loc) · 1.3 KB
/
tuxmath-2.0.3.ebuild
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
# Copyright 1999-2016 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
EAPI=5
inherit eutils gnome2-utils games
MY_PN="${PN}_w_fonts"
DESCRIPTION="Educational arcade game where you have to solve maths problems"
HOMEPAGE="http://tux4kids.alioth.debian.org/tuxmath/"
SRC_URI="mirror://debian/pool/main/t/${PN}/${PN}_${PV}.orig.tar.gz"
LICENSE="GPL-2 OFL-1.1"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="nls svg"
RDEPEND="dev-games/t4k-common[svg?]
dev-libs/libxml2:2
media-libs/libsdl:0[video]
media-libs/sdl-pango
media-libs/sdl-image[jpeg,png]
media-libs/sdl-mixer[mod]
media-libs/sdl-net
nls? ( virtual/libintl )
svg? (
gnome-base/librsvg:2
x11-libs/cairo
)"
DEPEND="${RDEPEND}
virtual/pkgconfig
nls? ( sys-devel/gettext )"
S=${WORKDIR}/${MY_PN}-${PV}
src_prepare() {
sed -i -e '/\bdoc\b/d' Makefile.in || die
}
src_configure() {
egamesconf \
--localedir=/usr/share/locale \
$(use_enable nls) \
$(usex svg "" "--without-rsvg")
}
src_install() {
default
doicon -s scalable data/images/icons/${PN}.svg
make_desktop_entry ${PN} "TuxMath"
dodoc doc/{README,TODO,changelog}
prepgamesdirs
}
pkg_preinst() {
games_pkg_preinst
gnome2_icon_savelist
}
pkg_postinst() {
games_pkg_postinst
gnome2_icon_cache_update
}
pkg_postrm() {
gnome2_icon_cache_update
}