summaryrefslogtreecommitdiffstats
path: root/yocto-poky/meta/recipes-kernel/perf/perf.bb
diff options
context:
space:
mode:
Diffstat (limited to 'yocto-poky/meta/recipes-kernel/perf/perf.bb')
-rw-r--r--yocto-poky/meta/recipes-kernel/perf/perf.bb18
1 files changed, 14 insertions, 4 deletions
diff --git a/yocto-poky/meta/recipes-kernel/perf/perf.bb b/yocto-poky/meta/recipes-kernel/perf/perf.bb
index 22bd3c820..3d6ffb30f 100644
--- a/yocto-poky/meta/recipes-kernel/perf/perf.bb
+++ b/yocto-poky/meta/recipes-kernel/perf/perf.bb
@@ -88,6 +88,7 @@ EXTRA_OEMAKE = '\
'
EXTRA_OEMAKE += "\
+ 'DESTDIR=${D}' \
'prefix=${prefix}' \
'bindir=${bindir}' \
'sharedir=${datadir}' \
@@ -110,7 +111,7 @@ do_compile() {
do_install() {
# Linux kernel build system is expected to do the right thing
unset CFLAGS
- oe_runmake DESTDIR=${D} install
+ oe_runmake install
# we are checking for this make target to be compatible with older perf versions
if [ "${@perf_feature_enabled('perf-scripting', 1, 0, d)}" = "1" ] && grep -q install-python_ext ${S}/tools/perf/Makefile*; then
oe_runmake DESTDIR=${D} install-python_ext
@@ -164,6 +165,10 @@ do_configure_prepend () {
sed -i 's,CC = $(CROSS_COMPILE)gcc,#CC,' ${S}/tools/lib/api/Makefile
sed -i 's,AR = $(CROSS_COMPILE)ar,#AR,' ${S}/tools/lib/api/Makefile
fi
+ if [ -e "${S}/tools/lib/subcmd/Makefile" ]; then
+ sed -i 's,CC = $(CROSS_COMPILE)gcc,#CC,' ${S}/tools/lib/subcmd/Makefile
+ sed -i 's,AR = $(CROSS_COMPILE)ar,#AR,' ${S}/tools/lib/subcmd/Makefile
+ fi
if [ -e "${S}/tools/perf/config/feature-checks/Makefile" ]; then
sed -i 's,CC := $(CROSS_COMPILE)gcc -MD,CC += -MD,' ${S}/tools/perf/config/feature-checks/Makefile
fi
@@ -179,6 +184,11 @@ do_configure_prepend () {
sed -i 's,#include "tests/tests.h",#include "tests/tests.h"\n#include "util/debug.h",' ${S}/tools/perf/arch/arm/tests/dwarf-unwind.c
sed -i 's,#include "perf_regs.h",#include "perf_regs.h"\n#include "util/debug.h",' ${S}/tools/perf/arch/arm/util/unwind-libunwind.c
fi
+
+ # use /usr/bin/env instead of version specific python
+ for s in `find ${S}/tools/perf/scripts/python/ -name '*.py'`; do
+ sed -i 's,/usr/bin/python2,/usr/bin/env python,' "${s}"
+ done
}
python do_package_prepend() {
@@ -192,7 +202,7 @@ PACKAGES =+ "${PN}-archive ${PN}-tests ${PN}-perl ${PN}-python"
RDEPENDS_${PN} += "elfutils bash"
RDEPENDS_${PN}-archive =+ "bash"
-RDEPENDS_${PN}-python =+ "bash python"
+RDEPENDS_${PN}-python =+ "bash python python-modules"
RDEPENDS_${PN}-perl =+ "bash perl perl-modules"
RDEPENDS_${PN}-tests =+ "python"
@@ -200,10 +210,10 @@ RSUGGESTS_SCRIPTING = "${@perf_feature_enabled('perf-scripting', '${PN}-perl ${P
RSUGGESTS_${PN} += "${PN}-archive ${PN}-tests ${RSUGGESTS_SCRIPTING}"
FILES_${PN} += "${libexecdir}/perf-core ${exec_prefix}/libexec/perf-core ${libdir}/traceevent"
-FILES_${PN}-dbg += "${libdir}/python*/site-packages/.debug"
FILES_${PN}-archive = "${libdir}/perf/perf-core/perf-archive"
-FILES_${PN}-tests = "${libdir}/perf/perf-core/tests"
+FILES_${PN}-tests = "${libdir}/perf/perf-core/tests ${libexecdir}/perf-core/tests"
FILES_${PN}-python = "${libdir}/python*/site-packages ${libdir}/perf/perf-core/scripts/python"
+FILES_${PN}-python += "${libexecdir}/perf-core/scripts/python/*"
FILES_${PN}-perl = "${libdir}/perf/perf-core/scripts/perl"
OpenPOWER on IntegriCloud