summaryrefslogtreecommitdiff
blob: 832566c0f6c0df82b8d0bc027e5398b4a6de59c2 (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

EAPI=7

MY_P=${PN}-3.0-${PV}
DESCRIPTION="A library for registering global keyboard shortcuts"
HOMEPAGE="https://github.com/kupferlauncher/keybinder"
SRC_URI="https://github.com/kupferlauncher/keybinder/releases/download/${PN}-3.0-v${PV}/${MY_P}.tar.gz"
S=${WORKDIR}/${MY_P}

LICENSE="MIT"
SLOT="3"
KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~mips ppc ppc64 x86"
IUSE="+introspection"

RDEPEND="x11-libs/gtk+:3[X]
	x11-libs/libX11
	x11-libs/libXext
	x11-libs/libXrender"
DEPEND="${RDEPEND}"
BDEPEND="virtual/pkgconfig
	introspection? ( dev-libs/gobject-introspection )"

src_configure() {
	local myconf=(
		$(use_enable introspection)
	)

	econf "${myconf[@]}"
}

src_install() {
	default
	find "${D}" -name '*.la' -delete || die
}

pkg_preinst() {
	# remove old symlink as otherwise the files will be installed
	# in the wrong directory
	if [[ -h ${EROOT}/usr/share/gtk-doc/html/keybinder-3.0 ]]; then
		rm "${EROOT}/usr/share/gtk-doc/html/keybinder-3.0" || die
	fi
}