diff options
| author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-03-03 10:59:25 +0000 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-03-05 10:22:56 -0800 |
| commit | 06f2f8ce0a3093973ca54b48f542f8485b666079 (patch) | |
| tree | dbcfa5c491eb2e5d237aa539cb7c6e77dc07dd6f /meta/conf/machine | |
| parent | d01dadfb87cfd2284b3e849d35a35fe5df0239c4 (diff) | |
| download | poky-06f2f8ce0a3093973ca54b48f542f8485b666079.tar.gz | |
meta: Convert getVar/getVarFlag(xxx, 1) -> (xxx, True)
Using "1" with getVar is bad coding style and "True" is preferred.
This patch is a sed over the meta directory of the form:
sed \
-e 's:\(\.getVar([^,()]*, \)1 *):\1True):g' \
-e 's:\(\.getVarFlag([^,()]*, [^,()]*, \)1 *):\1True):g' \
-i `grep -ril getVar *`
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/conf/machine')
| -rw-r--r-- | meta/conf/machine/include/arm/feature-arm-thumb.inc | 2 | ||||
| -rw-r--r-- | meta/conf/machine/include/tune-thumb.inc | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/meta/conf/machine/include/arm/feature-arm-thumb.inc b/meta/conf/machine/include/arm/feature-arm-thumb.inc index b7d6061a9b..d094529d2d 100644 --- a/meta/conf/machine/include/arm/feature-arm-thumb.inc +++ b/meta/conf/machine/include/arm/feature-arm-thumb.inc | |||
| @@ -5,7 +5,7 @@ | |||
| 5 | # but requires more instructions (140% for 70% smaller code) so may be | 5 | # but requires more instructions (140% for 70% smaller code) so may be |
| 6 | # slower. | 6 | # slower. |
| 7 | TUNEVALID[thumb] = "Use thumb instructions instead of ARM" | 7 | TUNEVALID[thumb] = "Use thumb instructions instead of ARM" |
| 8 | ARM_THUMB_M_OPT = "${@['-marm', '-mthumb'][d.getVar('ARM_INSTRUCTION_SET', 1) == 'thumb']}" | 8 | ARM_THUMB_M_OPT = "${@['-marm', '-mthumb'][d.getVar('ARM_INSTRUCTION_SET', True) == 'thumb']}" |
| 9 | TUNE_CCARGS += "${@bb.utils.contains("TUNE_FEATURES", "thumb", "${ARM_THUMB_M_OPT}", "", d)}" | 9 | TUNE_CCARGS += "${@bb.utils.contains("TUNE_FEATURES", "thumb", "${ARM_THUMB_M_OPT}", "", d)}" |
| 10 | OVERRIDES .= "${@bb.utils.contains("TUNE_FEATURES", "thumb", ":thumb", "", d)}" | 10 | OVERRIDES .= "${@bb.utils.contains("TUNE_FEATURES", "thumb", ":thumb", "", d)}" |
| 11 | 11 | ||
diff --git a/meta/conf/machine/include/tune-thumb.inc b/meta/conf/machine/include/tune-thumb.inc index 214e3b6ff2..a2392c2d59 100644 --- a/meta/conf/machine/include/tune-thumb.inc +++ b/meta/conf/machine/include/tune-thumb.inc | |||
| @@ -16,15 +16,15 @@ THUMB_INTERWORK ?= "yes" | |||
| 16 | # arm system and vice versa. It is strongly recommended that DISTROs not | 16 | # arm system and vice versa. It is strongly recommended that DISTROs not |
| 17 | # turn this off - the actual cost is very small. | 17 | # turn this off - the actual cost is very small. |
| 18 | 18 | ||
| 19 | OVERRIDE_THUMB = "${@['', ':thumb'][d.getVar('ARM_INSTRUCTION_SET', 1) == 'thumb']}" | 19 | OVERRIDE_THUMB = "${@['', ':thumb'][d.getVar('ARM_INSTRUCTION_SET', True) == 'thumb']}" |
| 20 | OVERRIDE_INTERWORK = "${@['', ':thumb-interwork'][d.getVar('THUMB_INTERWORK', 1) == 'yes']}" | 20 | OVERRIDE_INTERWORK = "${@['', ':thumb-interwork'][d.getVar('THUMB_INTERWORK', True) == 'yes']}" |
| 21 | OVERRIDES .= "${OVERRIDE_THUMB}${OVERRIDE_INTERWORK}" | 21 | OVERRIDES .= "${OVERRIDE_THUMB}${OVERRIDE_INTERWORK}" |
| 22 | 22 | ||
| 23 | # Compiler and linker options for application code and kernel code. These | 23 | # Compiler and linker options for application code and kernel code. These |
| 24 | # options ensure that the compiler has the correct settings for the selected | 24 | # options ensure that the compiler has the correct settings for the selected |
| 25 | # instruction set and interworking. | 25 | # instruction set and interworking. |
| 26 | ARM_INTERWORK_M_OPT = "${@['-mno-thumb-interwork', '-mthumb-interwork'][d.getVar('THUMB_INTERWORK', 1) == 'yes']}" | 26 | ARM_INTERWORK_M_OPT = "${@['-mno-thumb-interwork', '-mthumb-interwork'][d.getVar('THUMB_INTERWORK', True) == 'yes']}" |
| 27 | ARM_THUMB_M_OPT = "${@['-marm', '-mthumb'][d.getVar('ARM_INSTRUCTION_SET', 1) == 'thumb']}" | 27 | ARM_THUMB_M_OPT = "${@['-marm', '-mthumb'][d.getVar('ARM_INSTRUCTION_SET', True) == 'thumb']}" |
| 28 | 28 | ||
| 29 | # | 29 | # |
| 30 | TUNE_CCARGS += "${ARM_INTERWORK_M_OPT} ${ARM_THUMB_M_OPT}" | 30 | TUNE_CCARGS += "${ARM_INTERWORK_M_OPT} ${ARM_THUMB_M_OPT}" |
