summaryrefslogtreecommitdiff
blob: 4bab85426a6108b79cfc2547f00d52a6d80540c2 (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
# Copyright 1999-2016 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2

EAPI=6

IS_MULTILIB=true
GITHUB_A="msva"

inherit lua

DESCRIPTION="A set of Lua bindings for the Fast Artificial Neural Network (FANN) library."
HOMEPAGE="https://github.com/msva/lua-fann"

LICENSE="LGPL-2.1"
SLOT="0"
KEYWORDS=""
IUSE="doc examples"

RDEPEND="
	sci-mathematics/fann
"
DEPEND="
	${RDEPEND}
"

DOCS=(README.md)
HTML_DOCS=(doc/luafann.html)
EXAMPLES=(test/.)

all_lua_compile() {
	use doc && (
		emake docs
	)
}

each_lua_compile() {
	lua_default \
		LUA_IMPL="$(lua_get_lua)" \
		LUA_BIN="${LUA}" \
		LUA_INC="."
}

each_lua_test() {
	emake test
}

each_lua_install() {
	dolua fann.so
}