1 # Copyright 1999-2015 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
10 inherit eutils multilib versionator
13 PARROT_VERSION="6.7.0"
15 DESCRIPTION="Not Quite Perl, a Perl 6 bootstrapping compiler"
16 HOMEPAGE="http://rakudo.org/"
17 SRC_URI="https://github.com/perl6/${PN}/tarball/${PV} -> ${P}.tar.gz"
21 KEYWORDS="~x86 ~amd64"
22 IUSE="doc parrot java +moar"
23 REQUIRED_USE="|| ( parrot java moar )"
25 RDEPEND="parrot? ( >=dev-lang/parrot-${PARROT_VERSION}:=[unicode] )
26 java? ( >=virtual/jre-1.7 )
27 moar? ( =dev-lang/moarvm-${PV} )
30 java? ( >=virtual/jdk-1.7 )
33 S=${WORKDIR}/perl6-nqp-${GITCRAP}
36 use java && myconf+="jvm,"
37 use parrot && myconf+="parrot,"
38 use moar && myconf+="moar,"
39 perl Configure.pl --backend=${myconf} --prefix=/usr || die
40 # dirty hack to make dyncall not fail
41 sed -i -e 's/-Werror=missing-prototypes//' Makefile || die
42 sed -i -e 's/-Werror=missing-declarations//' Makefile || die
43 sed -i -e 's/-Werror=strict-prototypes//' Makefile || die
45 # more dirty hack to allow building with newer gcc
46 sed -i -e 's/-Werror=implicit-function-declaration//' Makefile || die
47 sed -i -e 's/-Werror=nested-externs//' Makefile || die
59 emake DESTDIR="${ED}" install || die
61 dodoc CREDITS README.pod || die
64 dodoc -r docs/* || die