mirror of
https://git.yoctoproject.org/poky
synced 2026-06-03 01:40:07 +00:00
oprofile: fix cross compile on powerpc and add libpfm4 dep
Fixes [YOCTO #3717] (From OE-Core rev: 88959e42411a40b15fe8907da00a97a7732a9cc1) Signed-off-by: Matthew McClintock <msm@freescale.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
44f5f3f128
commit
f1dc17dc32
@@ -0,0 +1,35 @@
|
|||||||
|
Upstream-Status: Submitted
|
||||||
|
|
||||||
|
From cd8aafe5ca48e8d809188df6e42f20efd5cbefd1 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Matthew McClintock <msm@freescale.com>
|
||||||
|
Date: Tue, 5 Feb 2013 11:05:00 -0600
|
||||||
|
Subject: [PATCH] fix powerpc cross compiling
|
||||||
|
|
||||||
|
You can't determine the target for running on by running uname
|
||||||
|
on the build machine. Use a better method instead.
|
||||||
|
|
||||||
|
Signed-off-by: Matthew McClintock <msm@freescale.com>
|
||||||
|
---
|
||||||
|
configure.ac | 4 ++--
|
||||||
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/configure.ac b/configure.ac
|
||||||
|
index a9b1ee4..4b73cdd 100644
|
||||||
|
--- a/configure.ac
|
||||||
|
+++ b/configure.ac
|
||||||
|
@@ -155,10 +155,10 @@ fi
|
||||||
|
|
||||||
|
AC_DEFINE_UNQUOTED(HAVE_PERF_EVENTS, $HAVE_PERF_EVENTS, [Kernel support for perf_events exists])
|
||||||
|
|
||||||
|
+AC_CANONICAL_HOST
|
||||||
|
if test "$HAVE_PERF_EVENTS" = "1"; then
|
||||||
|
PFM_LIB=
|
||||||
|
- arch="`uname -m`"
|
||||||
|
- if test "$arch" = "ppc64" || test "$arch" = "ppc"; then
|
||||||
|
+ if test "$host_cpu" = "powerpc"; then
|
||||||
|
AC_CHECK_HEADER(perfmon/pfmlib.h,,[AC_MSG_ERROR([pfmlib.h not found; usually provided in papi devel package])])
|
||||||
|
AC_CHECK_LIB(pfm,pfm_get_os_event_encoding, HAVE_LIBPFM3='0'; HAVE_LIBPFM='1', [
|
||||||
|
AC_CHECK_LIB(pfm, pfm_get_event_name, HAVE_LIBPFM3='1'; HAVE_LIBPFM='1',
|
||||||
|
--
|
||||||
|
1.7.9.7
|
||||||
|
|
||||||
@@ -1,15 +1,18 @@
|
|||||||
require oprofile.inc
|
require oprofile.inc
|
||||||
|
|
||||||
PR = "${INC_PR}.1"
|
PR = "${INC_PR}.2"
|
||||||
|
|
||||||
DEPENDS += "virtual/kernel"
|
DEPENDS += "virtual/kernel"
|
||||||
|
DEPENDS_append_powerpc = " libpfm4"
|
||||||
|
DEPENDS_append_powerpc64 = " libpfm4"
|
||||||
|
|
||||||
SRC_URI += "${SOURCEFORGE_MIRROR}/${BPN}/${BPN}-${PV}.tar.gz \
|
SRC_URI += "${SOURCEFORGE_MIRROR}/${BPN}/${BPN}-${PV}.tar.gz \
|
||||||
file://0001-Add-rmb-definition-for-AArch64-architecture.patch \
|
file://0001-Add-rmb-definition-for-AArch64-architecture.patch \
|
||||||
file://0001-OProfile-doesn-t-build-for-32-bit-ppc-the-operf_util.patch \
|
file://0001-OProfile-doesn-t-build-for-32-bit-ppc-the-operf_util.patch \
|
||||||
file://0001-Handle-early-perf_events-kernel-without-PERF_RECORD_.patch \
|
file://0001-Handle-early-perf_events-kernel-without-PERF_RECORD_.patch \
|
||||||
file://0001-Fix-up-configure-to-handle-architectures-that-do-not.patch \
|
file://0001-Fix-up-configure-to-handle-architectures-that-do-not.patch \
|
||||||
file://0001-Change-configure-to-look-for-libpfm4-function-first-.patch"
|
file://0001-Change-configure-to-look-for-libpfm4-function-first-.patch \
|
||||||
|
file://0001-fix-powerpc-cross-compiling.patch "
|
||||||
|
|
||||||
SRC_URI[md5sum] = "6d127023af1dd1cf24e15411229f3cc8"
|
SRC_URI[md5sum] = "6d127023af1dd1cf24e15411229f3cc8"
|
||||||
SRC_URI[sha256sum] = "ab45900fa1a23e5d5badf3c0a55f26c17efe6e184efcf00b371433751fa761bc"
|
SRC_URI[sha256sum] = "ab45900fa1a23e5d5badf3c0a55f26c17efe6e184efcf00b371433751fa761bc"
|
||||||
|
|||||||
Reference in New Issue
Block a user