summary refs log tree commit diff
path: root/x11-misc/devour/devour-9999.ebuild
diff options
context:
space:
mode:
authorAzat Bahawi <azahi@teknik.io>2020-11-24 08:54:58 +0300
committerAzat Bahawi <azahi@teknik.io>2020-11-24 08:55:00 +0300
commit49c62898ebdd980451fa5a0668f5f4b3d2afb6ff (patch)
treee9ddc91a6803cc509298b8448e116c14d662a128 /x11-misc/devour/devour-9999.ebuild
parentx11-misc/focus: Add package (diff)
x11-misc/devour: Bump version, update build
Package-Manager: Portage-3.0.9, Repoman-3.0.2
Signed-off-by: Azat Bahawi <azahi@teknik.io>
Diffstat (limited to '')
-rw-r--r--x11-misc/devour/devour-9999.ebuild27
1 files changed, 23 insertions, 4 deletions
diff --git a/x11-misc/devour/devour-9999.ebuild b/x11-misc/devour/devour-9999.ebuild
index a79c528..2b88b39 100644
--- a/x11-misc/devour/devour-9999.ebuild
+++ b/x11-misc/devour/devour-9999.ebuild
@@ -4,18 +4,20 @@
 EAPI=7
 
 if [[ ${PV} == *9999 ]]; then
-	inherit git-r3
+	SCM="git-r3"
 	EGIT_REPO_URI="https://github.com/salman-abedin/devour.git"
 fi
 
-DESCRIPTION="Window Manager agnostic swallowing feature for terminal emulators"
+inherit toolchain-funcs "${SCM}"
+
+DESCRIPTION="Window manager agnostic swallowing feature for terminal emulators"
 HOMEPAGE="https://github.com/salman-abedin/devour"
 
 if [[ ${PV} == *9999 ]]; then
 	SRC_URI=""
 	KEYWORDS=""
 else
-	SRC_URI="https://github.com/salman-abedin/devour/archive/v${PV}.tar.gz"
+	SRC_URI="https://github.com/salman-abedin/devour/archive/${PV}.tar.gz"
 	KEYWORDS="~amd64 ~x86"
 fi
 
@@ -27,6 +29,23 @@ DEPEND="x11-libs/libX11"
 RDEPEND="${DEPEND}"
 BDEPEND=""
 
+DOCS=( README.md )
+
+src_prepare() {
+	default
+
+	sed -e 's/^CFLAGS =/CFLAGS +=/' \
+		-e 's/ -s //g' \
+		-e 's/ -O2//g' \
+		-i Makefile || die
+}
+
+src_compile() {
+	emake \
+		CC="$(tc-getCC)"
+}
+
 src_install() {
-	emake DESTDIR="${D}" PREFIX="/usr" BINPREFIX="/usr/bin" install
+	dobin ${PN}
+	einstalldocs
 }

Consider giving Nix/NixOS a try! <3