summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sys-process/btop/btop-1.2.7-r1.ebuild')
-rw-r--r--sys-process/btop/btop-1.2.7-r1.ebuild44
1 files changed, 44 insertions, 0 deletions
diff --git a/sys-process/btop/btop-1.2.7-r1.ebuild b/sys-process/btop/btop-1.2.7-r1.ebuild
new file mode 100644
index 000000000000..59381b7f2690
--- /dev/null
+++ b/sys-process/btop/btop-1.2.7-r1.ebuild
@@ -0,0 +1,44 @@
+# Copyright 2021-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit xdg-utils
+
+DESCRIPTION="A monitor of resources"
+HOMEPAGE="https://github.com/aristocratos/btop"
+SRC_URI="https://github.com/aristocratos/btop/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+src_prepare() {
+ default
+ # btop installs README.md to /usr/share/btop by default
+ sed -i '/^.*cp -p README.md.*$/d' Makefile || die
+}
+
+src_compile() {
+ # Disable btop optimization flags, since we have our flags in CXXFLAGS
+ emake OPTFLAGS=""
+}
+
+src_install() {
+ emake \
+ PREFIX="${EPREFIX}/usr" \
+ DESTDIR="${D}" \
+ install
+
+ dodoc README.md CHANGELOG.md
+}
+
+pkg_postinst() {
+ xdg_desktop_database_update
+ xdg_icon_cache_update
+}
+
+pkg_postrm() {
+ xdg_desktop_database_update
+ xdg_icon_cache_update
+}