summaryrefslogtreecommitdiff
blob: 883ebd7c7fee00896afc1b9076b330c19804ce44 (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
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=7

inherit autotools bash-completion-r1

MY_PV="${PV//_beta/-beta}"
DESCRIPTION="DF-SHOW is a Unix-like rewrite of some of the applications from DF-EDIT"
HOMEPAGE="https://github.com/roberthawdon/dfshow"
SRC_URI="https://github.com/roberthawdon/dfshow/archive/v${MY_PV}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/${PN}-${MY_PV}"

LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64 ~x86"

DEPEND="dev-libs/libconfig:=
	sys-libs/ncurses:0=
"
RDEPEND="${DEPEND}"

src_prepare() {
	default
	sed -i 's/LDADD = -lncursesw -lm -lconfig/LDADD = -lncursesw -lm -lconfig -ltinfow/' Makefile.am ||
		die "sed in Makefile.am failed"

	eautoreconf
}

src_install() {
	default

	newbashcomp "${S}/misc/auto-completion/bash/sf-completion.bash" sf-completion
	newbashcomp "${S}/misc/auto-completion/bash/show-completion.bash" show-completion

	insinto /usr/share/zsh/site-functions
	doins "${S}/misc/auto-completion/zsh/_sf"
	doins "${S}/misc/auto-completion/zsh/_show"
}