diff options
author | mcgrathr <mcgrathr@chromium.org> | 2015-09-21 20:25:43 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-09-22 03:26:20 +0000 |
commit | cc3a331e1bc91166a5d51fc1fa44fba49d1fb461 (patch) | |
tree | 5a34c1f250272a6229b6f6dcd0fd2749b123d8d6 /build/toolchain | |
parent | c40e2eda4b7656f997e2255282098b0abba31224 (diff) | |
download | chromium_src-cc3a331e1bc91166a5d51fc1fa44fba49d1fb461.zip chromium_src-cc3a331e1bc91166a5d51fc1fa44fba49d1fb461.tar.gz chromium_src-cc3a331e1bc91166a5d51fc1fa44fba49d1fb461.tar.bz2 |
GN: Harmonize ARM compiler settings with GYP
This changes various defaults about the ARM compiler setup so
that GN matches what GYP does today:
* Prefix for cross tools is arm-linux-gnueabihf- not arm-linux-gnueabi-
* arm_float_abi defaults to hard for non-Android ARMv7
* Non-CrOS ARM builds use the ARM sysroot by default
(the one installed by install-build-deps.sh --arm)
* Define a clang_arm toolchain, pass it the -no-integrated and
-target arm-linux-gnueabihf and switches as GYP does
R=dpranke@chromium.org, sbc@chromium.org
BUG=
Review URL: https://codereview.chromium.org/1352313002
Cr-Commit-Position: refs/heads/master@{#350100}
Diffstat (limited to 'build/toolchain')
-rw-r--r-- | build/toolchain/linux/BUILD.gn | 30 |
1 files changed, 25 insertions, 5 deletions
diff --git a/build/toolchain/linux/BUILD.gn b/build/toolchain/linux/BUILD.gn index 94d9a16..84a790d 100644 --- a/build/toolchain/linux/BUILD.gn +++ b/build/toolchain/linux/BUILD.gn @@ -16,14 +16,34 @@ if (use_goma) { compiler_prefix = "" } +gcc_toolchain("clang_arm") { + prefix = rebase_path("//third_party/llvm-build/Release+Asserts/bin", + root_build_dir) + cc = "${compiler_prefix}$prefix/clang" + cxx = "${compiler_prefix}$prefix/clang++" + + toolprefix = "arm-linux-gnueabihf-" + readelf = "${toolprefix}readelf" + ar = "${toolprefix}ar" + ld = cxx + readelf = "${toolprefix}readelf" + nm = "${toolprefix}nm" + + toolchain_cpu = "arm" + toolchain_os = "linux" + is_clang = true +} + gcc_toolchain("arm") { - cc = "${compiler_prefix}arm-linux-gnueabi-gcc" - cxx = "${compiler_prefix}arm-linux-gnueabi-g++" + toolprefix = "arm-linux-gnueabihf-" + + cc = "${compiler_prefix}${toolprefix}gcc" + cxx = "${compiler_prefix}${toolprefix}g++" - ar = "arm-linux-gnueabi-ar" + ar = "${toolprefix}ar" ld = cxx - readelf = "arm-linux-gnueabi-readelf" - nm = "arm-linux-gnueabi-nm" + readelf = "${toolprefix}readelf" + nm = "${toolprefix}nm" toolchain_cpu = "arm" toolchain_os = "linux" |