summaryrefslogtreecommitdiffstats
path: root/build
diff options
context:
space:
mode:
authormmoss@chromium.org <mmoss@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-16 00:53:59 +0000
committermmoss@chromium.org <mmoss@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-10-16 00:53:59 +0000
commit521240186735d7f63fbd5ec2b420f7ad170c565b (patch)
tree4e95f491ca8c0c4bc86f5ab9c4ceb104121df6a3 /build
parent296383bd8221c9d006d6bbc35badf1a434be51fa (diff)
downloadchromium_src-521240186735d7f63fbd5ec2b420f7ad170c565b.zip
chromium_src-521240186735d7f63fbd5ec2b420f7ad170c565b.tar.gz
chromium_src-521240186735d7f63fbd5ec2b420f7ad170c565b.tar.bz2
Default to building for the same architecture as the build host.
BUG=24766 Review URL: http://codereview.chromium.org/271113 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@29230 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'build')
-rw-r--r--build/common.gypi15
1 files changed, 13 insertions, 2 deletions
diff --git a/build/common.gypi b/build/common.gypi
index b5af77a..bd11ee4 100644
--- a/build/common.gypi
+++ b/build/common.gypi
@@ -35,8 +35,19 @@
# builds).
'buildtype%': 'Dev',
- # The architecture that we're building on.
- 'target_arch%': 'ia32',
+ # Compute the architecture that we're building for. Default to the
+ # architecture that we're building on.
+ 'conditions': [
+ [ 'OS=="linux"', {
+ # This handles the Linux platforms we generally deal with. Anything
+ # else gets passed through, which probably won't work very well; such
+ # hosts should pass an explicit target_arch to gyp.
+ 'target_arch%':
+ '<!(uname -m | sed -e "s/i.86/ia32/;s/x86_64/x64/;s/arm.*/arm/")'
+ }, { # OS!="linux"
+ 'target_arch%': 'ia32',
+ }],
+ ],
# We do want to build Chromium with Breakpad support in certain
# situations. I.e. for Chrome bot.