Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(349)

Unified Diff: build/common.gypi

Issue 1009103003: MIPS32EL: Add clang compiler flags for MIPS32 - Android (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/common.gypi
diff --git a/build/common.gypi b/build/common.gypi
index 61224bae88ffe1dafe7907399e7d978251167c52..14284d88876580d5a44abf647d4d036382baa35e 100644
--- a/build/common.gypi
+++ b/build/common.gypi
@@ -4088,23 +4088,63 @@
['android_webview_build==0', {
'conditions': [
['mips_arch_variant=="r6"', {
- 'cflags': ['-mips32r6', '-Wa,-mips32r6'],
'conditions': [
- ['OS=="android"', {
+ ['clang==1', {
+ 'cflags': [ '-target mipsel-linux-gnu', '-march=mips32r6', ],
+ 'ldflags': [ '-target mipsel-linux-gnu', ],
+ }, { # clang==0
+ 'cflags': ['-mips32r6', '-Wa,-mips32r6', ],
+ }],
+ ['clang==0 and OS=="android"', {
'ldflags': ['-mips32r6', '-Wl,-melf32ltsmip',],
}],
],
}],
['mips_arch_variant=="r2"', {
- 'cflags': ['-mips32r2', '-Wa,-mips32r2'],
'conditions': [
['mips_float_abi=="hard" and mips_fpu_mode!=""', {
'cflags': ['-m<(mips_fpu_mode)'],
}],
+ ['clang==1', {
+ 'conditions': [
+ ['OS=="android"', {
+ 'cflags': [ '-target mipsel-linux-android', '-march=mipsel', '-mcpu=mips32r2'],
+ 'ldflags': [ '-target mipsel-linux-android', ],
+ }],
+ ],
+ }, { # clang==0
+ 'cflags': ['-mips32r2', '-Wa,-mips32r2', ],
+ }],
],
}],
['mips_arch_variant=="r1"', {
- 'cflags': ['-mips32', '-Wa,-mips32'],
+ 'conditions': [
+ ['clang==1', {
+ 'conditions': [
+ ['OS=="android"', {
+ 'cflags': [ '-target mipsel-linux-android', '-march=mipsel', '-mcpu=mips32'],
+ 'ldflags': [ '-target mipsel-linux-android', ],
+ }],
+ ],
+ }, { # clang==0
+ 'cflags': ['-mips32', '-Wa,-mips32', ],
+ }],
+ ],
+ }],
+ ['clang==1', {
+ 'cflags!': [
+ # Clang does not support the following options.
+ '-finline-limit=64',
+ ],
+ 'cflags': [
+ # TODO(gordanac) Enable integrated-as.
+ '-no-integrated-as',
Nico 2015/11/30 18:47:47 Everything builds fine for me with OS=android targ
+ '-B<(android_toolchain)', # Else /usr/bin/as gets picked up.
+ ],
+ 'ldflags': [
+ # Let clang find the ld in the NDK.
+ '--gcc-toolchain=<(android_toolchain)/..',
+ ],
}],
['mips_dsp_rev==1', {
'cflags': ['-mdsp'],
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698