diff options
author | Robert Yang <liezhi.yang@windriver.com> | 2018-09-05 15:16:17 +0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2018-09-13 07:42:28 +0100 |
commit | 285b9a0d8eb3c931287e1f3af5c03d8f83a418e4 (patch) | |
tree | c72b1418a1428111d77fff3f9f137d2d7a570081 /meta/conf/bitbake.conf | |
parent | cb4134f7982b339c85460efb40fa640db963988a (diff) | |
download | poky-285b9a0d8eb3c931287e1f3af5c03d8f83a418e4.tar.gz |
oe/utils.py: Add vartrue()
It can be used to simplify code like:
"${@['iffalse', 'iftrue'][var]}"
(From OE-Core rev: fc5a5af7bc3619f575988a75efc0c4fe15478b2d)
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/conf/bitbake.conf')
-rw-r--r-- | meta/conf/bitbake.conf | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf index faef77142a..dbadeb38aa 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}" | |||
610 | # Disabled until the option works properly -feliminate-dwarf2-dups | 610 | # Disabled until the option works properly -feliminate-dwarf2-dups |
611 | FULL_OPTIMIZATION = "-O2 -pipe ${DEBUG_FLAGS}" | 611 | FULL_OPTIMIZATION = "-O2 -pipe ${DEBUG_FLAGS}" |
612 | DEBUG_OPTIMIZATION = "-O -fno-omit-frame-pointer ${DEBUG_FLAGS} -pipe" | 612 | DEBUG_OPTIMIZATION = "-O -fno-omit-frame-pointer ${DEBUG_FLAGS} -pipe" |
613 | SELECTED_OPTIMIZATION = "${@d.getVar(['FULL_OPTIMIZATION', 'DEBUG_OPTIMIZATION'][d.getVar('DEBUG_BUILD') == '1'])}" | 613 | SELECTED_OPTIMIZATION = "${@d.getVar(oe.utils.vartrue('DEBUG_BUILD', 'DEBUG_OPTIMIZATION', 'FULL_OPTIMIZATION', d))}" |
614 | SELECTED_OPTIMIZATION[vardeps] += "FULL_OPTIMIZATION DEBUG_OPTIMIZATION" | 614 | SELECTED_OPTIMIZATION[vardeps] += "FULL_OPTIMIZATION DEBUG_OPTIMIZATION" |
615 | BUILD_OPTIMIZATION = "-O2 -pipe" | 615 | BUILD_OPTIMIZATION = "-O2 -pipe" |
616 | 616 | ||