Commit de6c3bcc authored by Arthur Eubanks's avatar Arthur Eubanks Committed by Commit Bot

Use downloaded gcc toolchain in compiler-rt tests

To prevent relying on out of date libraries on the host (e.g. libstdc++).

Bug: 1132936, 1109801, 1077698
Change-Id: Ie4d8320668391c63a869e8fd8cf679877ffd19c1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2446892Reviewed-by: default avatarNico Weber <thakis@chromium.org>
Commit-Queue: Arthur Eubanks <aeubanks@google.com>
Cr-Commit-Position: refs/heads/master@{#813580}
parent 2af35437
...@@ -576,11 +576,13 @@ def main(): ...@@ -576,11 +576,13 @@ def main():
base_cmake_args.append('-DPython3_EXECUTABLE=/nonexistent') base_cmake_args.append('-DPython3_EXECUTABLE=/nonexistent')
if args.gcc_toolchain: if args.gcc_toolchain:
# Don't use the custom gcc toolchain when building compiler-rt tests; those # Force compiler-rt tests to use our gcc toolchain (including libstdc++.so)
# tests are built with the just-built Clang, and target both i386 and x86_64 # because the one on the host may be too old.
# for example, so should use the system's libstdc++.
base_cmake_args.append( base_cmake_args.append(
'-DCOMPILER_RT_TEST_COMPILER_CFLAGS=--gcc-toolchain=') '-DCOMPILER_RT_TEST_COMPILER_CFLAGS=--gcc-toolchain=' +
args.gcc_toolchain + ' -Wl,-rpath,' +
os.path.join(args.gcc_toolchain, 'lib64') + ' -Wl,-rpath,' +
os.path.join(args.gcc_toolchain, 'lib32'))
if sys.platform == 'win32': if sys.platform == 'win32':
base_cmake_args.append('-DLLVM_USE_CRT_RELEASE=MT') base_cmake_args.append('-DLLVM_USE_CRT_RELEASE=MT')
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment