summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
Diffstat (limited to 'meta')
-rw-r--r--meta/conf/distro/include/security_flags.inc1
-rw-r--r--meta/recipes-kernel/perf/perf.bb9
2 files changed, 9 insertions, 1 deletions
diff --git a/meta/conf/distro/include/security_flags.inc b/meta/conf/distro/include/security_flags.inc
index 2972f05b4e..d97a6edb0f 100644
--- a/meta/conf/distro/include/security_flags.inc
+++ b/meta/conf/distro/include/security_flags.inc
@@ -69,4 +69,3 @@ SECURITY_LDFLAGS:pn-xserver-xorg = "${SECURITY_X_LDFLAGS}"
69TARGET_CC_ARCH:append:pn-binutils = " ${SELECTED_OPTIMIZATION}" 69TARGET_CC_ARCH:append:pn-binutils = " ${SELECTED_OPTIMIZATION}"
70TARGET_CC_ARCH:append:pn-gcc = " ${SELECTED_OPTIMIZATION}" 70TARGET_CC_ARCH:append:pn-gcc = " ${SELECTED_OPTIMIZATION}"
71TARGET_CC_ARCH:append:pn-gdb = " ${SELECTED_OPTIMIZATION}" 71TARGET_CC_ARCH:append:pn-gdb = " ${SELECTED_OPTIMIZATION}"
72TARGET_CC_ARCH:append:pn-perf = " ${SELECTED_OPTIMIZATION}"
diff --git a/meta/recipes-kernel/perf/perf.bb b/meta/recipes-kernel/perf/perf.bb
index 675acfaf26..a392166e73 100644
--- a/meta/recipes-kernel/perf/perf.bb
+++ b/meta/recipes-kernel/perf/perf.bb
@@ -73,6 +73,15 @@ SPDX_S = "${S}/tools/perf"
73# supported kernel. 73# supported kernel.
74LDFLAGS="-ldl -lutil" 74LDFLAGS="-ldl -lutil"
75 75
76# Perf's build system adds its own optimization flags for most TUs,
77# overriding the flags included here. But for some, perf does not add
78# any -O option, so ensure the distro's chosen optimization gets used
79# for those. Since ${SELECTED_OPTIMIZATION} always includes
80# ${DEBUG_FLAGS} which in turn includes ${DEBUG_PREFIX_MAP}, this also
81# ensures perf is built with appropriate -f*-prefix-map options,
82# avoiding the 'buildpaths' QA warning.
83TARGET_CC_ARCH += "${SELECTED_OPTIMIZATION}"
84
76EXTRA_OEMAKE = '\ 85EXTRA_OEMAKE = '\
77 V=1 \ 86 V=1 \
78 VF=1 \ 87 VF=1 \