diff options
author | brettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-12-31 04:59:41 +0000 |
---|---|---|
committer | brettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-12-31 04:59:41 +0000 |
commit | 0b3c983df5dca7830a097387e7bea6f5a90fd93c (patch) | |
tree | 816286ef9038a30cdf1ad6b30b89fbab9182470f /build/toolchain | |
parent | dc7d29d65b10d0b478cac4dbbe53aa554284d996 (diff) | |
download | chromium_src-0b3c983df5dca7830a097387e7bea6f5a90fd93c.zip chromium_src-0b3c983df5dca7830a097387e7bea6f5a90fd93c.tar.gz chromium_src-0b3c983df5dca7830a097387e7bea6f5a90fd93c.tar.bz2 |
Remove -fstack-protector-strong from the ChromeOS GN build.
This trybots said this was an unknown option, so the comment I was basing my
usage of "strong" on in common.gypi must be out-of-date. The GYP build does not
seem to specify "strong" in any cases except on Mac.
Hook up compiler finding to the Android build.
R=jam@chromium.org
Review URL: https://codereview.chromium.org/99333020
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242746 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'build/toolchain')
-rw-r--r-- | build/toolchain/android/BUILD.gn | 6 | ||||
-rw-r--r-- | build/toolchain/android/find_android_compiler.py (renamed from build/toolchain/linux/find_android_compilers.py) | 12 |
2 files changed, 13 insertions, 5 deletions
diff --git a/build/toolchain/android/BUILD.gn b/build/toolchain/android/BUILD.gn index 7710cd0..c277263 100644 --- a/build/toolchain/android/BUILD.gn +++ b/build/toolchain/android/BUILD.gn @@ -44,10 +44,8 @@ if (is_gyp) { # This script will find the compilers for the given Android toolchain # directory. - # TODO(brettw) write this script which locates the Android compilers. - #android_compilers = exec_script("find_android_compilers.py", - # [android_toolchain], "value") - android_compilers = ["gcc", "g++", "gcc", "g++"] + android_compilers = exec_script("find_android_compiler.py", + [android_toolchain], "value") gyp_header = "'make_global_settings': [" + "['CC', '" + android_compilers[0] + "']," + diff --git a/build/toolchain/linux/find_android_compilers.py b/build/toolchain/android/find_android_compiler.py index 7061ecc..d806ead 100644 --- a/build/toolchain/linux/find_android_compilers.py +++ b/build/toolchain/android/find_android_compiler.py @@ -19,8 +19,18 @@ if len(sys.argv) != 2: android_toolchain = sys.argv[1] cc = glob.glob(android_toolchain + "/*-gcc") cxx = glob.glob(android_toolchain + "/*-g++") + +# We tolerate "no matches." In the Android AOSP WebView build, it runs this +# logic and the directory doesn't exist, giving no matches. But that build runs +# GYP to generate Android Makefiles which specify the compiler separately. So +# all we need to do in this case is ignore the error and continue with empty +# target compilers. +if len(cc) == 0: + cc = [""] +if len(cxx) == 0: + cxx = [""] if len(cc) != 1 or len(cxx) != 1: - print "Either none or more than one matching compiler." + print "More than one matching compiler." sys.exit(1) # Get the host compilers from the current path. |