Bug 1745129 - Use --gcc-toolchain=... rather than -gcc-toolchain .... r=firefox-build-system-reviewers,andi

Apparently the latter doesn't work anymore with clang 14.

Differential Revision: https://phabricator.services.mozilla.com/D133330
This commit is contained in:
Mike Hommey 2021-12-09 08:28:11 +00:00
parent ec5f85f981
commit c60168e1b6
2 changed files with 2 additions and 3 deletions

View File

@ -12,7 +12,7 @@ case "$target" in
# clang will do any number of interesting things with host tools unless we tell
# it to use the NDK tools.
extra_opts="-gcc-toolchain $(dirname $(dirname $TOOLCHAIN_PREFIX))"
extra_opts="--gcc-toolchain=$(dirname $(dirname $TOOLCHAIN_PREFIX))"
CPPFLAGS="$extra_opts -D__ANDROID_API__=$android_version $CPPFLAGS"
ASFLAGS="$extra_opts $ASFLAGS"
LDFLAGS="$extra_opts $LDFLAGS"

View File

@ -376,8 +376,7 @@ def extra_toolchain_flags(
android_system,
"-isystem",
os.path.join(android_sysroot, "usr", "include"),
"-gcc-toolchain",
toolchain_dir,
"--gcc-toolchain={}".format(toolchain_dir),
"-D__ANDROID_API__=%d" % android_version,
]
return flags