]> code.ossystems Code Review - openembedded-core.git/commitdiff
perf: fix v3.17 powerpc compilation issues
authorBruce Ashfield <bruce.ashfield@windriver.com>
Mon, 8 Sep 2014 03:57:29 +0000 (23:57 -0400)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Wed, 10 Sep 2014 14:19:58 +0000 (15:19 +0100)
The powerpc perf arch port has two issues in the current 3.17-rc
seriers. Undefined dwarf symbols and undefined pr_debug calls.

commit a60335ba [perf tools powerpc: Adjust callchain based on DWARF debug info]
introduces skip-callchain-idx.c, and breaks the perf build.

Until fixes get into the mainline kernel, we temporarily fix the issues by
adding a forced linke to -ldw and modifying skip-callchain-idx.c to include
the proper debug files for pr_debug.

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
meta/recipes-kernel/perf/perf.bb

index cbd03f27ba56ae470858740c5b04a04075718a7f..8112986a08732d2917ec325109bb54e18404996a 100644 (file)
@@ -78,6 +78,7 @@ EXTRA_OEMAKE = '\
     ARCH=${ARCH} \
     CC="${CC}" \
     AR="${AR}" \
+    EXTRA_CFLAGS="-ldw" \
     perfexecdir=${libexecdir} \
     NO_GTK2=1 ${TUI_DEFINES} NO_DWARF=1 ${LIBUNWIND_DEFINES} ${SCRIPTING_DEFINES} \
 '
@@ -143,6 +144,10 @@ do_configure_prepend () {
     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
+    # 3.17-rc1+ has a include issue for powerpc. Temporarily sed in the appropriate include
+    if [ -e "${S}/tools/perf/arch/powerpc/util/skip-callchain-idx.c" ]; then
+        sed -i 's,#include "util/callchain.h",#include "util/callchain.h"\n#include "util/debug.h",' ${S}/tools/perf/arch/powerpc/util/skip-callchain-idx.c
+    fi
 }
 
 python do_package_prepend() {