1 # Copyright 1999-2013 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
4 # @ECLASS: gnome-games.eclass
6 # Gnome team <gnome@gentoo.org>
8 # Author: Pacho Ramos <pacho@gentoo.org>
9 # @BLURB: An eclass to build gnome-games.
11 # An eclass to build gnome-games using proper phases from gnome2 and
16 die "Unsupported EAPI=${EAPI:-0} (too old) for ${ECLASS}"
21 die "Unsupported EAPI=${EAPI} (unknown) for ${ECLASS}"
25 inherit autotools games gnome2
27 EXPORT_FUNCTIONS pkg_setup src_prepare src_configure src_compile src_install pkg_preinst pkg_postinst pkg_postrm
29 if [[ ! ${_GNOME_GAMES} ]]; then
31 DEPEND=">=dev-util/intltool-0.50.2-r1"
32 RDEPEND="!gnome-extra/gnome-games"
34 # @FUNCTION: gnome-games_pkg_setup
36 # Set proper phase defaults
37 gnome-games_pkg_setup() {
38 debug-print-function ${FUNCNAME} "${@}"
42 # @FUNCTION: gnome-games_src_prepare
44 # Set proper phase defaults
45 gnome-games_src_prepare() {
46 debug-print-function ${FUNCNAME} "${@}"
48 # Fix intltoolize broken file:
49 # https://bugs.launchpad.net/intltool/+bug/398571
50 intltoolize --force --copy --automake || die "intltoolize failed"
56 # @FUNCTION: gnome-games_src_configure
58 # Set proper phase defaults, relying on gnome2_src_configure
59 # and passing extra arguments from egamesconf (games.eclass)
60 gnome-games_src_configure() {
61 debug-print-function ${FUNCNAME} "${@}"
62 gnome2_src_configure \
63 --prefix="${GAMES_PREFIX}" \
64 --libdir="$(games_get_libdir)" \
65 --sysconfdir="${GAMES_SYSCONFDIR}" \
66 --localstatedir=/var \
67 --localedir=/usr/share/locale \
71 # @FUNCTION: gnome-games_src_compile
73 # Set proper phase defaults
74 gnome-games_src_compile() {
75 debug-print-function ${FUNCNAME} "${@}"
79 # @FUNCTION: gnome-games_src_install
81 # Set proper phase defaults
82 gnome-games_src_install() {
83 debug-print-function ${FUNCNAME} "${@}"
88 # @FUNCTION: gnome-games_pkg_preinst
90 # Set proper phase defaults
91 gnome-games_pkg_preinst() {
92 debug-print-function ${FUNCNAME} "${@}"
97 # @FUNCTION: gnome-games_pkg_postinst
99 # Set proper phase defaults
100 gnome-games_pkg_postinst() {
101 debug-print-function ${FUNCNAME} "${@}"
106 # @FUNCTION: gnome-games_pkg_postrm
108 # Set proper phase defaults
109 gnome-games_pkg_postrm() {
110 debug-print-function ${FUNCNAME} "${@}"