commit: 7c9fb8355533da7ce8cd718b601528308056ee64
Author: Huang Rui <vowstar <AT> gmail <DOT> com>
AuthorDate: Sat Jun 13 15:36:49 2020 +0000
Commit: Andrew Ammerlaan <andrewammerlaan <AT> riseup <DOT> net>
CommitDate: Sat Jun 13 15:36:49 2020 +0000
URL: https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=7c9fb835
sys-process/nvtop: change IUSE order and move CMAKE_CONF to local
Optimize the ebuild file
Package-Manager: Portage-2.3.100, Repoman-2.3.22
Signed-off-by: Huang Rui <vowstar <AT> gmail.com>
sys-process/nvtop/nvtop-1.0.0.ebuild | 15 ++++++---------
1 file changed, 6 insertions(+), 9 deletions(-)
diff --git a/sys-process/nvtop/nvtop-1.0.0.ebuild
b/sys-process/nvtop/nvtop-1.0.0.ebuild
index 5d7ced8..b7b88af 100644
--- a/sys-process/nvtop/nvtop-1.0.0.ebuild
+++ b/sys-process/nvtop/nvtop-1.0.0.ebuild
@@ -19,7 +19,7 @@ fi
LICENSE="GPL-3"
SLOT="0"
-IUSE="unicode debug"
+IUSE="debug unicode"
RDEPEND="
sys-libs/ncurses:0=[unicode?]
@@ -32,20 +32,17 @@ BDEPEND="
virtual/pkgconfig
"
-BUILD_DIR="${WORKDIR}/build"
-
-CMAKE_CONF="
- !debug? ( -DCMAKE_BUILD_TYPE=Release )
- debug? ( -DCMAKE_BUILD_TYPE=Debug )
- unicode? ( -DCURSES_NEED_WIDE=TRUE )
-"
-
PATCHES=(
"${FILESDIR}"/${PN}-1.0.0-add-nvml.patch
"${FILESDIR}"/${PN}-1.0.0-fix-ncurses.patch
)
src_configure() {
+ local CMAKE_CONF="
+ !debug? ( -DCMAKE_BUILD_TYPE=Release )
+ debug? ( -DCMAKE_BUILD_TYPE=Debug )
+ unicode? ( -DCURSES_NEED_WIDE=TRUE )
+ "
local mycmakeargs=(
-DCMAKE_INSTALL_PREFIX="${EPREFIX}/usr"
-DNVML_INCLUDE_DIRS="${S}/include"