You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
81 lines
1.7 KiB
81 lines
1.7 KiB
5 years ago
|
# Copyright 1999-2019 Gentoo Authors
|
||
6 years ago
|
# Distributed under the terms of the GNU General Public License v2
|
||
|
|
||
|
EAPI=7
|
||
|
PYTHON_COMPAT=(python2_7)
|
||
|
|
||
|
inherit linux-info python-single-r1 toolchain-funcs
|
||
|
|
||
|
DESCRIPTION="User-space front-end for Ftrace"
|
||
|
HOMEPAGE="https://git.kernel.org/cgit/linux/kernel/git/rostedt/trace-cmd.git"
|
||
|
|
||
|
if [[ ${PV} == *9999 ]] ; then
|
||
|
EGIT_REPO_URI="https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/${PN}.git"
|
||
|
inherit git-r3
|
||
|
else
|
||
5 years ago
|
SRC_URI="https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/${PN}.git/snapshot/${PN}-v${PV}.tar.gz"
|
||
6 years ago
|
KEYWORDS="~amd64 ~x86"
|
||
|
S="${WORKDIR}/${PN}-v${PV}"
|
||
|
fi
|
||
|
|
||
|
LICENSE="GPL-2+ LGPL-2.1+"
|
||
|
SLOT="0"
|
||
5 years ago
|
IUSE="+audit doc python udis86"
|
||
6 years ago
|
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
|
||
|
|
||
5 years ago
|
RDEPEND="audit? ( sys-process/audit )
|
||
|
python? ( ${PYTHON_DEPS} )
|
||
5 years ago
|
udis86? ( dev-libs/udis86 )"
|
||
6 years ago
|
DEPEND="${RDEPEND}
|
||
|
sys-kernel/linux-headers
|
||
|
python? (
|
||
|
virtual/pkgconfig
|
||
|
dev-lang/swig
|
||
|
)
|
||
5 years ago
|
|
||
6 years ago
|
doc? ( app-text/asciidoc )"
|
||
|
|
||
|
CONFIG_CHECK="
|
||
|
~TRACING
|
||
|
~FTRACE
|
||
|
~BLK_DEV_IO_TRACE"
|
||
|
|
||
|
PATCHES=(
|
||
|
"${FILESDIR}"/${PN}-2.7-makefile.patch
|
||
5 years ago
|
"${FILESDIR}"/${PN}-2.7-soname.patch
|
||
6 years ago
|
)
|
||
|
|
||
|
pkg_setup() {
|
||
|
linux-info_pkg_setup
|
||
|
use python && python-single-r1_pkg_setup
|
||
|
}
|
||
|
|
||
|
src_configure() {
|
||
5 years ago
|
MAKEOPTS+=" prefix=/usr
|
||
|
libdir=/usr/$(get_libdir)
|
||
|
CC=$(tc-getCC)
|
||
|
AR=$(tc-getAR)
|
||
|
$(usex audit '' '' 'NO_AUDIT=1')"
|
||
6 years ago
|
|
||
|
if use python; then
|
||
|
MAKEOPTS+=" PYTHON_VERS=${EPYTHON//python/python-}"
|
||
|
MAKEOPTS+=" python_dir=$(python_get_sitedir)/${PN}"
|
||
|
else
|
||
|
MAKEOPTS+=" NO_PYTHON=1"
|
||
|
fi
|
||
|
|
||
|
use udis86 || MAKEOPTS+=" NO_UDIS86=1"
|
||
|
}
|
||
|
|
||
|
src_compile() {
|
||
5 years ago
|
emake V=1 all_cmd libs
|
||
6 years ago
|
use doc && emake doc
|
||
5 years ago
|
|
||
6 years ago
|
}
|
||
|
|
||
|
src_install() {
|
||
5 years ago
|
emake DESTDIR="${D}" V=1 install install_libs
|
||
6 years ago
|
use doc && emake DESTDIR="${D}" install_doc
|
||
5 years ago
|
|
||
6 years ago
|
}
|