summaryrefslogtreecommitdiff
blob: 1efd7f51b8f0abef4fd6a825caab9e7f1b3443c0 (plain)
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
# Copyright 1999-2015 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$

EAPI=5

inherit base

DESCRIPTION="Neko is a high-level dynamically typed programming language."
HOMEPAGE="http://nekovm.org/"
SRC_URI="http://nekovm.org/media/${P}.tar.gz"

LICENSE=""
SLOT="0"
KEYWORDS="amd64 ~arm ~ppc x86"
IUSE=""

DEPEND="dev-libs/boehm-gc[threads]"
RDEPEND="${DEPEND}"

MAKEOPTS+=" -j1"

src_configure() {
	# Reading things from stdin doesn't work, so just replace with "s" (i.e. skip).
	sed -i 's/readline();/"s";/' src/tools/install.neko || die "Unable to modify install.neko."
}

src_prepare() {
	epatch "${FILESDIR}/${PV}-soname.patch"

	# fix path to use lib64 for appropriate architectures
	sed -i -e "s:\/lib\/:\/$(get_libdir)\/:g" Makefile \
		|| die "patching Makefile failed"
	sed -i -e "s:\/lib$:\/$(get_libdir):" Makefile \
		|| die "patching Makefile failed"
}

src_install() {
	mkdir -p "${D}/usr/"{$(get_libdir),bin} # Missing from install target
	emake INSTALL_PREFIX="${D}/usr" install
}