blob: 578cae7255d937e786a93ef776eff5a3ccbb1cfa (
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
|
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
# NOTICE: miniKanren does not define a library interface :(
# so we will make a wrapper to load miniKanren...
EAPI=8
COMMIT=2d50ec5002fe052f5c2f2d72530dcbeb8760fde8
MY_PN=miniKanren
inherit wrapper
DESCRIPTION="Canonical miniKanren implementation (on Chez Scheme)"
HOMEPAGE="https://github.com/miniKanren/miniKanren"
SRC_URI="https://github.com/miniKanren/${MY_PN}/archive/${COMMIT}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/${MY_PN}-${COMMIT}"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64"
IUSE="source"
RESTRICT="strip"
RDEPEND="dev-scheme/chez:="
DEPEND="${RDEPEND}"
MINIKANREN_HOME=/usr/lib/chezscheme/${MY_PN}
src_compile() {
local s=( $( find . -name "*.scm" -exec printf "\"%s\" " {} + ) )
local c="(import (chezscheme)) (for-each compile-library (list ${s[@]}))"
echo "${c}" | chezscheme --quiet --optimize-level 3 || die
}
src_install() {
insinto ${MINIKANREN_HOME}
doins *.so
use source && doins *.scm
make_wrapper ${MY_PN} "chezscheme mk.so" ${MINIKANREN_HOME}
einstalldocs
}
|