aboutsummaryrefslogtreecommitdiff
blob: 2554a40ab9efc5cfe38a54394cd4ee8dd715ba28 (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-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=7

inherit multilib toolchain-funcs

DESCRIPTION="Minimal Scheme implementation for use as an extension language"
HOMEPAGE="http://synthcode.com/scheme/chibi/"

if [[ "${PV}" == *9999* ]]; then
	inherit git-r3
	EGIT_REPO_URI="https://github.com/ashinn/${PN}-scheme.git"
else
	SRC_URI="https://github.com/ashinn/${PN}-scheme/archive/refs/tags/${PV}.tar.gz -> ${P}.tar.gz"
	KEYWORDS="~amd64"
	S="${WORKDIR}/${PN}-scheme-${PV}"
fi

LICENSE="BSD"
SLOT="0"

src_configure() {
	tc-export CC

	export PREFIX="${EPREFIX}/usr"
	export LIBDIR="${EPREFIX}/usr/$(get_libdir)"
	export SOLIBDIR="${EPREFIX}/usr/$(get_libdir)"
	export DESTDIR="${D}"

	# if ldconfig (stored in LDCONFIG variable) exists it is ran
	export LDCONFIG="0"
}

src_install() {
	einstalldocs

	emake install

	dosym chibi-scheme /usr/bin/chibi
}