1 # Copyright 1999-2013 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
5 # @ECLASS: gnome-games.eclass
7 # Gnome team <gnome@gentoo.org>
9 # Author: Pacho Ramos <pacho@gentoo.org>
10 # @BLURB: An eclass to build gnome-games.
12 # An eclass to build gnome-games using proper phases from gnome2 and
17 die "Unsupported EAPI=${EAPI:-0} (too old) for ${ECLASS}"
22 die "Unsupported EAPI=${EAPI} (unknown) for ${ECLASS}"
26 inherit autotools games gnome2
28 EXPORT_FUNCTIONS pkg_setup src_prepare src_configure src_compile src_install pkg_preinst pkg_postinst pkg_postrm
30 if [[ ! ${_GNOME_GAMES} ]]; then
32 DEPEND=">=dev-util/intltool-0.50.2-r1"
33 RDEPEND="!gnome-extra/gnome-games"
35 # @FUNCTION: gnome-games_pkg_setup
37 # Set proper phase defaults
38 gnome-games_pkg_setup() {
39 debug-print-function ${FUNCNAME} "${@}"
43 # @FUNCTION: gnome-games_src_prepare
45 # Set proper phase defaults
46 gnome-games_src_prepare() {
47 debug-print-function ${FUNCNAME} "${@}"
49 # Fix intltoolize broken file:
50 # https://bugs.launchpad.net/intltool/+bug/398571
51 intltoolize --force --copy --automake || die "intltoolize failed"
57 # @FUNCTION: gnome-games_src_configure
59 # Set proper phase defaults, relying on gnome2_src_configure
60 # and passing extra arguments from egamesconf (games.eclass)
61 gnome-games_src_configure() {
62 debug-print-function ${FUNCNAME} "${@}"
63 gnome2_src_configure \
64 --prefix="${GAMES_PREFIX}" \
65 --libdir="$(games_get_libdir)" \
66 --sysconfdir="${GAMES_SYSCONFDIR}" \
67 --localstatedir=/var \
68 --localedir=/usr/share/locale \
72 # @FUNCTION: gnome-games_src_compile
74 # Set proper phase defaults
75 gnome-games_src_compile() {
76 debug-print-function ${FUNCNAME} "${@}"
80 # @FUNCTION: gnome-games_src_install
82 # Set proper phase defaults
83 gnome-games_src_install() {
84 debug-print-function ${FUNCNAME} "${@}"
89 # @FUNCTION: gnome-games_pkg_preinst
91 # Set proper phase defaults
92 gnome-games_pkg_preinst() {
93 debug-print-function ${FUNCNAME} "${@}"
98 # @FUNCTION: gnome-games_pkg_postinst
100 # Set proper phase defaults
101 gnome-games_pkg_postinst() {
102 debug-print-function ${FUNCNAME} "${@}"
107 # @FUNCTION: gnome-games_pkg_postrm
109 # Set proper phase defaults
110 gnome-games_pkg_postrm() {
111 debug-print-function ${FUNCNAME} "${@}"