Openembedded Core Discussions
 help / color / mirror / Atom feed
* [PATCH] bitbake.conf: Use -Og in DEBUG_OPTIMIZATION
@ 2019-02-27  7:04 Khem Raj
  2019-02-27  7:19 ` Adrian Bunk
  0 siblings, 1 reply; 3+ messages in thread
From: Khem Raj @ 2019-02-27  7:04 UTC (permalink / raw)
  To: openembedded-core

-Og is for optimized debugging experience.
this makes this consistent across different compilers especially gcc and
clang, -O in clang is equal to -O2 where as in gcc its similar to -O1
so it was not giving consistent debugging experience across compilers

Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 meta/conf/bitbake.conf | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf
index 1c5369ec98..758e89f126 100644
--- a/meta/conf/bitbake.conf
+++ b/meta/conf/bitbake.conf
@@ -610,7 +610,7 @@ DEBUG_FLAGS ?= "-g -feliminate-unused-debug-types ${DEBUG_PREFIX_MAP}"
 
 # Disabled until the option works properly -feliminate-dwarf2-dups
 FULL_OPTIMIZATION = "-O2 -pipe ${DEBUG_FLAGS}"
-DEBUG_OPTIMIZATION = "-O -fno-omit-frame-pointer ${DEBUG_FLAGS} -pipe"
+DEBUG_OPTIMIZATION = "-Og -fno-omit-frame-pointer ${DEBUG_FLAGS} -pipe"
 SELECTED_OPTIMIZATION = "${@d.getVar(oe.utils.vartrue('DEBUG_BUILD', 'DEBUG_OPTIMIZATION', 'FULL_OPTIMIZATION', d))}"
 SELECTED_OPTIMIZATION[vardeps] += "FULL_OPTIMIZATION DEBUG_OPTIMIZATION DEBUG_BUILD"
 BUILD_OPTIMIZATION = "${@oe.utils.vartrue('DEBUG_BUILD', '-O -g -feliminate-unused-debug-types -fno-omit-frame-pointer', '-O2', d)} -pipe"
-- 
2.21.0



^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-02-27 19:44 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-02-27  7:04 [PATCH] bitbake.conf: Use -Og in DEBUG_OPTIMIZATION Khem Raj
2019-02-27  7:19 ` Adrian Bunk
2019-02-27 19:44   ` Khem Raj

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox