|
|
Created:
11 years, 2 months ago by Michael Moss Modified:
9 years, 7 months ago CC:
chromium-reviews_googlegroups.com Visibility:
Public. |
DescriptionDefault to building for the same architecture as the build host.
BUG=24766
Patch Set 1 #
Total comments: 2
Patch Set 2 : comments #Messages
Total messages: 9 (0 generated)
This doesn't handle the automatic build directory renaming that we talked about in the bug. I looked at it some more, and it seemed too messy, and maybe not even possible without support from outside our gyp files, so I think we're better off waiting for --generator-output support. Anybody who wants to build multiple archs can still do it with a pretty simple wrapper script.
http://codereview.chromium.org/271113/diff/1/2 File build/common.gypi (right): http://codereview.chromium.org/271113/diff/1/2#newcode46 Line 46: '<!(uname -m | sed -e "s/i.86/ia32/;s/x86_64/x64/;s/arm.*/arm/")' Does this work in both the make build and the scons build? If it works for both, LGTM. Lots of shell code in the gyp files makes me nervous.
LGTM http://codereview.chromium.org/271113/diff/1/2 File build/common.gypi (right): http://codereview.chromium.org/271113/diff/1/2#newcode38 Line 38: # The architecture that we're building for. Default to the The initial "The" here sorta lost its referent. Maybe make it say "Compute the archi..." ?
> http://codereview.chromium.org/271113/diff/1/2#newcode46 > Line 46: '<!(uname -m | sed -e "s/i.86/ia32/;s/x86_64/x64/;s/arm.*/arm/")' > Does this work in both the make build and the scons build? If it works for > both, LGTM. Lots of shell code in the gyp files makes me nervous. Works for both for me.
This CL breaks the build on my 64bit machine, because native_client is still built into 32bit binary. You probably need update ./native_client/build/common.gypi as well. Regards James Su
Hmm, I'm not on VPN right now to look at this file, but why doesn't this inherit from the higher-level common.gypi? Is it really resetting values that have already been set? That seems wrong. On Thu, Oct 15, 2009 at 8:39 PM, <suzhe@chromium.org> wrote: > This CL breaks the build on my 64bit machine, because native_client is still > built into 32bit binary. You probably need update > ./native_client/build/common.gypi as well. > > Regards > James Su > > http://codereview.chromium.org/271113 >
I'm not familiar with the gyp code, however check the file: http://nativeclient.googlecode.com/svn/trunk/src/native_client/build/common.gypi: 'variables': { ... # The architecture that we're building for (x86, arm). 'target_arch%': 'ia32', ... }, ... Seems it do overwrites the value. Regards James Su On 2009/10/16 04:02:03, Michael Moss wrote: > Hmm, I'm not on VPN right now to look at this file, but why doesn't > this inherit from the higher-level common.gypi? Is it really resetting > values that have already been set? That seems wrong. > > On Thu, Oct 15, 2009 at 8:39 PM, <mailto:suzhe@chromium.org> wrote: > > This CL breaks the build on my 64bit machine, because native_client is still > > built into 32bit binary. You probably need update > > ./native_client/build/common.gypi as well. > > > > Regards > > James Su > > > > http://codereview.chromium.org/271113 > >
On Thu, Oct 15, 2009 at 9:09 PM, <suzhe@chromium.org> wrote: > I'm not familiar with the gyp code, however check the file: > http://nativeclient.googlecode.com/svn/trunk/src/native_client/build/comm= on.gypi: > > =A0'variables': { > ... > =A0 =A0# The architecture that we're building for (x86, arm). > =A0 =A0'target_arch%': 'ia32', > ... > =A0}, > ... > > Seems it do overwrites the value. The '%' suffix tells it to not overwrite the value if there is already a value set for that variable. Somewhere along the way, the Chromium gyp values are not getting passed to the NaCl gyp configs. BTW, as mentioned in a separate thread, setting GYP_DEFINES=3D"target_arch=3Dia32" in the environment should work around this problem for now (by forcing everything to build as 32-bit, like it did before). Michael > On 2009/10/16 04:02:03, Michael Moss wrote: >> >> Hmm, I'm not on VPN right now to look at this file, but why doesn't >> this inherit from the higher-level common.gypi? Is it really resetting >> values that have already been set? That seems wrong. > >> On Thu, Oct 15, 2009 at 8:39 PM, =A0<mailto:suzhe@chromium.org> wrote: >> > This CL breaks the build on my 64bit machine, because native_client is >> > still >> > built into 32bit binary. You probably need update >> > ./native_client/build/common.gypi as well. >> > >> > Regards >> > James Su >> > >> > http://codereview.chromium.org/271113 >> > > > > > http://codereview.chromium.org/271113 >
I see, thanks. I'll live with the workaround for now. On 2009/10/16 04:33:06, Michael Moss wrote: > On Thu, Oct 15, 2009 at 9:09 PM, <mailto:suzhe@chromium.org> wrote: > > I'm not familiar with the gyp code, however check the file: > > http://nativeclient.googlecode.com/svn/trunk/src/native_client/build/comm= > on.gypi: > > > > =A0'variables': { > > ... > > =A0 =A0# The architecture that we're building for (x86, arm). > > =A0 =A0'target_arch%': 'ia32', > > ... > > =A0}, > > ... > > > > Seems it do overwrites the value. > > The '%' suffix tells it to not overwrite the value if there is already > a value set for that variable. Somewhere along the way, the Chromium > gyp values are not getting passed to the NaCl gyp configs. > > BTW, as mentioned in a separate thread, setting > GYP_DEFINES=3D"target_arch=3Dia32" in the environment should work around > this problem for now (by forcing everything to build as 32-bit, like > it did before). > > Michael > > > On 2009/10/16 04:02:03, Michael Moss wrote: > >> > >> Hmm, I'm not on VPN right now to look at this file, but why doesn't > >> this inherit from the higher-level common.gypi? Is it really resetting > >> values that have already been set? That seems wrong. > > > >> On Thu, Oct 15, 2009 at 8:39 PM, =A0<mailto:suzhe@chromium.org> wrote: > >> > This CL breaks the build on my 64bit machine, because native_client is > >> > still > >> > built into 32bit binary. You probably need update > >> > ./native_client/build/common.gypi as well. > >> > > >> > Regards > >> > James Su > >> > > >> > http://codereview.chromium.org/271113 > >> > > > > > > > > > http://codereview.chromium.org/271113 > > |