blob: be1cfb0b03c5c78af994b837931b17a3744620ee (
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
|
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
EAPI=4
inherit eutils toolchain-funcs multilib
DESCRIPTION="Takes node.js' architecture and dependencies and fits it in the Lua language"
HOMEPAGE="http://luvit.io/"
SRC_URI="http://${PN}.io/dist/${PV}/${P}.tar.gz"
KEYWORDS="~amd64 ~x86"
SLOT="0"
IUSE=""
LICENSE="Apache-2.0 MIT"
# fails in portage environment
# succeeds if run manually
RESTRICT="test"
RDEPEND="dev-lang/luajit:2
>=dev-libs/yajl-2.0.2
net-libs/http-parser
dev-libs/libuv"
DEPEND="${RDEPEND}
dev-util/pkgconfig"
src_prepare() {
# fix build system and remove references
# to bundled sources
epatch "${FILESDIR}"/${PV}-makefile.patch \
"${FILESDIR}"/${PV}-includes.patch
sed \
-e "s:^YAJL_VERSION=.*:YAJL_VERSION=$(pkg-config --modversion yajl):" \
-e "s:^LUAJIT_VERSION=.*:LUAJIT_VERSION=$(pkg-config --modversion luajit):" \
-i Makefile || die "sed failed"
}
src_configure() {
# skip python build system
:
}
src_compile() {
rm -r deps || die
tc-export CC AR
emake all
}
src_install() {
emake PREFIX=/usr LIBDIR=$(get_libdir) DESTDIR="${D}" install
}
|