commit:     c1353a0dafb7b645df615f423ed69ddff119a258
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Mon Dec 21 23:51:16 2020 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Mon Dec 21 23:52:11 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c1353a0d

dev-util/uftrace: migrate to lua-single.eclass

Closes: https://bugs.gentoo.org/752675
Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 dev-util/uftrace/uftrace-0.9.4-r100.ebuild | 61 ++++++++++++++++++++++++++++++
 profiles/package.mask                      |  1 +
 2 files changed, 62 insertions(+)

diff --git a/dev-util/uftrace/uftrace-0.9.4-r100.ebuild 
b/dev-util/uftrace/uftrace-0.9.4-r100.ebuild
new file mode 100644
index 00000000000..87ccea5aec8
--- /dev/null
+++ b/dev-util/uftrace/uftrace-0.9.4-r100.ebuild
@@ -0,0 +1,61 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+LUA_COMPAT=( luajit )
+
+inherit bash-completion-r1 lua-single
+
+DESCRIPTION="Function (graph) tracer for user-space"
+HOMEPAGE="https://github.com/namhyung/uftrace";
+SRC_URI="https://github.com/namhyung/uftrace/archive/v${PV}.tar.gz -> 
${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="bash-completion capstone lua"
+
+REQUIRED_USE="lua? ( ${LUA_REQUIRED_USE} )"
+
+RESTRICT="test"
+
+RDEPEND="
+       sys-libs/ncurses:=
+       virtual/libelf:=
+       capstone? ( dev-libs/capstone:0= )
+       lua? ( ${LUA_DEPS} )
+"
+DEPEND="${RDEPEND}"
+
+src_prepare() {
+       default
+       sed -i -e "s/ARCH/MYARCH/g" -e "/ldconfig/d" -e "/bash.completion/d" 
Makefile || die
+}
+
+src_configure() {
+       local myconf=(
+               $(use_with capstone)
+               --without-libpython
+       )
+       if use lua && use lua_single_target_luajit; then
+               myconf+=(
+                       --with-libluajit
+               )
+       else
+               myconf+=(
+                       --without-libluajit
+               )
+       fi
+       econf "${myconf[@]}"
+}
+
+src_compile() {
+       emake V=1
+}
+
+src_install() {
+       default
+       dodoc doc/*.{md,gif,png}
+       use bash-completion && newbashcomp misc/bash-completion.sh uftrace
+}

diff --git a/profiles/package.mask b/profiles/package.mask
index caec4c46509..fc1d28408bc 100644
--- a/profiles/package.mask
+++ b/profiles/package.mask
@@ -510,6 +510,7 @@ kde-apps/kdebase-meta:5
 >=dev-util/geany-plugins-1.37-r100
 >=dev-util/hermes-2.8
 >=dev-util/sysdig-0.27.1-r100
+>=dev-util/uftrace-0.9.4-r100
 =games-action/minetest-5.3.0-r100
 >=games-arcade/jvgs-0.5-r100
 >=games-emulation/fceux-2.2.3-r100

Reply via email to