aboutsummaryrefslogtreecommitdiffstats
path: root/app-editors/kakoune/kakoune-9999.ebuild
blob: 4bff6937e9ed3b31119e303f321eb9052164cd15 (plain) (blame)
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 2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=7

inherit toolchain-funcs

if [[ ${PV} == 9999* ]] ; then
	inherit git-r3
	EGIT_REPO_URI="https://github.com/mawww/kakoune.git"
	KEYWORDS=""
else
	SRC_URI="https://github.com/mawww/kakoune/releases/download/v${PV}/kakoune-${PV}.tar.bz2"
	KEYWORDS="amd64"
	RESTRICT="mirror"
fi

DESCRIPTION="Selection-oriented code editor inspired by vim"
HOMEPAGE="https://kakoune.org"

LICENSE="Unlicense"
SLOT="0"
IUSE="debug static"

BDEPEND="virtual/pkgconfig"
RDEPEND="sys-libs/ncurses:0=[unicode]"
DEPEND="${RDEPEND} virtual/pkgconfig"

src_configure() {
	tc-export CXX
	export debug=$(usex debug)
	export static=$(usex static)
}

src_compile() {
	emake -C src
}

src_install() {
	emake -C src DESTDIR="${D}" PREFIX="${EPREFIX}/usr" docdir="${ED%/}/usr/share/doc/${PF}" install
}