kbuild: dummy-tools, fix inverted tests for gcc
PATCH 1/1 kbuild: dummy-tools, fix inverted tests for gcc
There is a test in Kconfig which takes inverted value of a compiler check:
* config CC_HAS_INT128
def_bool !$(cc-option,$(m64-flag) -D__SIZEOF_INT128__=0)
This results in CC_HAS_INT128 not being in super-config generated by dummy-tools. So take this into account in the gcc script.
--- scripts/dummy-tools/gcc | 5 +++++ 1 file changed, 5 insertions(+)
scripts/dummy-tools/gcc +5 -0
@@ -85,3 +85,8 @@ if arg_contain -print-file-name=plugin "$@"; then echo $plugin_dir exit 0 fi + +# inverted return value +if arg_contain -D__SIZEOF_INT128__=0 "$@"; then + exit 1 +fi
Signature · 1 line
2.30.1
Quoted 4 lines · Jiri Slaby
There is a test in
Kconfigwhich takes inverted value of a compiler check:
* configCC_HAS_INT128
Quoted 8 lines
def_bool !$(cc-option,$(m64-flag) -D__SIZEOF_INT128__=0)This results in
CC_HAS_INT128not being in super-config generated by dummy-tools. So take this into account in the gcc script.Signed-off-by Jiri Slaby <[email protected]>Cc Masahiro Yamada <[email protected]>---
Applied to linux-kbuild/fixes.
Thanks.
We could fix init/Kconfig to use the positive logic as follows, but I guess (hope) this conditional will go away
when we raise the GCC min version next time.
So, I am fine with fixing this in dummy-tools.
init/Kconfig +1 -2
@@ -849,7 +849,7 @@ config ARCH_WANT_BATCHED_UNMAP_TLB_FLUSH bool config CC_HAS_INT128 - def_bool !$(cc-option,$(m64-flag) -D__SIZEOF_INT128__=0) && 64BIT + def_bool $(success,echo '__int128 x;' | $(CC) $(CLANG_FLAGS) -x c - -c -o /dev/null) && 64BIT #
# For architectures that know their GCC __int128 support is sound
Signature · 2 lines
Best Regards Masahiro Yamada