1 # Copyright 1999-2015 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
7 if [[ ${PV} == *9999* ]]; then
9 EGIT_REPO_URI="git://anongit.gentoo.org/proj/catalyst.git"
14 SRC_URI="mirror://gentoo/${P}.tar.bz2
15 https://dev.gentoo.org/~jmbsvicetto/distfiles/${P}.tar.bz2
16 https://dev.gentoo.org/~zerochaos/distfiles/${P}.tar.bz2"
17 KEYWORDS="alpha amd64 arm arm64 hppa ia64 ~mips ppc ppc64 s390 sh sparc x86 ~x86-fbsd"
20 PYTHON_COMPAT=( python2_7 )
22 inherit eutils multilib python-single-r1 ${SRC_ECLASS}
24 DESCRIPTION="Release metatool used for creating releases based on Gentoo Linux"
25 HOMEPAGE="https://www.gentoo.org/proj/en/releng/catalyst/"
29 IUSE="ccache kernel_linux"
40 amd64? ( >=sys-boot/syslinux-3.72 )
41 ia64? ( sys-fs/dosfstools )
42 x86? ( >=sys-boot/syslinux-3.72 )
43 ccache? ( dev-util/ccache )
44 kernel_linux? ( app-misc/zisofs-tools >=sys-fs/squashfs-tools-2.1 )
48 REQUIRED_USE=${PYTHON_REQUIRED_USE}
52 einfo "Enabling ccache support for catalyst."
54 ewarn "By default, ccache support for catalyst is disabled."
55 ewarn "If this is not what you intended,"
56 ewarn "then you should add ccache to your USE."
60 einfo "The template spec files are now installed by default. You can find"
61 einfo "them under /usr/share/doc/${PF}/examples"
62 einfo "and they are considered to be the authorative source of information"
66 python-single-r1_pkg_setup
70 insinto /usr/$(get_libdir)/${PN}
71 exeinto /usr/$(get_libdir)/${PN}
72 doexe catalyst || die "copying catalyst"
74 if [[ ${PV} == 3.9999* ]]; then
75 doins -r modules files || die "copying files"
77 doins -r arch modules livecd || die "copying files"
80 for x in targets/*; do
81 exeinto /usr/$(get_libdir)/${PN}/$x
82 doexe $x/* || die "copying ${x}"
85 # Here is where we actually enable ccache
87 sed -i -e 's:options="autoresume kern:options="autoresume ccache kern:' \
90 sed -i -e "s:/usr/lib/catalyst:/usr/$(get_libdir)/catalyst:" \
93 make_wrapper catalyst /usr/$(get_libdir)/${PN}/catalyst
95 doins files/catalyst.conf files/catalystrc || die "copying configuration"
96 insinto /usr/share/doc/${PF}/examples
97 doins examples/* || die
99 doman files/catalyst.1 files/catalyst-spec.5
101 python_fix_shebang "${ED}usr/$(get_libdir)/catalyst/catalyst"
102 python_optimize "${ED}"
106 einfo "You can find more information about catalyst by checking out the"
107 einfo "catalyst project page at:"
108 einfo "https://www.gentoo.org/proj/en/releng/catalyst/index.xml"