summaryrefslogtreecommitdiff
blob: 793c2c0815548a40ca23fb9501b15262bbf1b60b (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
45
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=7
inherit desktop multilib toolchain-funcs

DESCRIPTION="Small dynamic tiling window manager for X11"
HOMEPAGE="https://github.com/conformal/spectrwm"
SRC_URI="https://github.com/conformal/spectrwm/archive/${PN^^}_${PV//./_}.tar.gz -> ${P}.tar.gz"

LICENSE="ISC"
SLOT="0"
KEYWORDS="~amd64 ~x86"

RDEPEND="
	!x11-wm/scrotwm
	x11-misc/dmenu
"
DEPEND="
	x11-libs/libX11
	x11-libs/libXcursor
	x11-libs/libXrandr
	x11-libs/libXtst
	x11-libs/xcb-util
"
PATCHES=(
	"${FILESDIR}"/${PN}-3.2.0-gentoo.patch
)
S=${WORKDIR}/${PN}-${PN^^}_${PV//./_}

src_compile() {
	tc-export CC PKG_CONFIG
	emake -C linux PREFIX="${EROOT}/usr" LIBDIR="${EROOT}/usr/$(get_libdir)"
}

src_install() {
	emake -C linux PREFIX="${EROOT}/usr" LIBDIR="${EROOT}/usr/$(get_libdir)" \
		DESTDIR="${D}" install

	insinto /etc
	doins ${PN}.conf
	dodoc CHANGELOG.md README.md ${PN}_*.conf {initscreen,screenshot}.sh

	make_session_desktop ${PN} ${PN}
}