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

Issue 141433015: GN build fixes, mostly for Mac. (Closed)

Created:
6 years, 11 months ago by brettw
Modified:
6 years, 11 months ago
Reviewers:
Nico
CC:
chromium-reviews
Visibility:
Public.

Description

GN build fixes, mostly for Mac. This hooks up detection for the "-arch" flag on Mac to set the GYP "ARCH" xcode variable. GN then removes the -arch argument from the compiler args, since GYP will then re-add it based on the ARCH value. Previously, not doing this resulting in mutliple "-arch" arguments to the compiler since GYP would always insert its own. Disables some warnings on Windows for the re2 target to match the GYP build. The third warning (4018) that the GYP build sets is disabled globally so there's no need to do it for this target. Hooks up some iOS SDK stuff. BUG=336667 TBR=thakis@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=247206

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : #

Patch Set 4 : put back sha1 file #

Total comments: 4
Unified diffs Side-by-side diffs Delta from patch set Stats (+85 lines, -7 lines) Patch
M build/config/BUILDCONFIG.gn View 1 1 chunk +5 lines, -0 lines 1 comment Download
M build/config/clang/BUILD.gn View 1 1 chunk +1 line, -1 line 2 comments Download
M build/config/compiler/BUILD.gn View 1 1 chunk +7 lines, -5 lines 1 comment Download
A build/config/ios/ios_sdk.gni View 1 2 1 chunk +10 lines, -0 lines 0 comments Download
A build/config/ios/ios_sdk.py View 1 1 chunk +19 lines, -0 lines 0 comments Download
M build/config/sysroot.gni View 1 2 1 chunk +3 lines, -0 lines 0 comments Download
M third_party/re2/BUILD.gn View 1 chunk +4 lines, -1 line 0 comments Download
M tools/gn/gyp_binary_target_writer.cc View 1 2 3 chunks +36 lines, -0 lines 0 comments Download

Messages

Total messages: 7 (0 generated)
brettw
iOS stuff is mostly a stab in the dark but it seems to work on ...
6 years, 11 months ago (2014-01-27 06:52:37 UTC) #1
brettw
I'm TBRing this since it requires a binary push to get started on the next ...
6 years, 11 months ago (2014-01-27 07:40:33 UTC) #2
brettw
Committed patchset #4 manually as r247206 (presubmit successful).
6 years, 11 months ago (2014-01-27 07:41:39 UTC) #3
Nico
What do you think about starting with system tests before doing changes like this first? ...
6 years, 11 months ago (2014-01-27 19:42:26 UTC) #4
brettw
https://codereview.chromium.org/141433015/diff/80001/build/config/clang/BUILD.gn File build/config/clang/BUILD.gn (right): https://codereview.chromium.org/141433015/diff/80001/build/config/clang/BUILD.gn#newcode18 build/config/clang/BUILD.gn:18: if (is_mac || is_ios) { Yeah, I'm still trying ...
6 years, 11 months ago (2014-01-28 02:13:41 UTC) #5
brettw
On 2014/01/27 19:42:26, Nico wrote: > What do you think about starting with system tests ...
6 years, 11 months ago (2014-01-28 02:22:29 UTC) #6
Nico
6 years, 11 months ago (2014-01-28 03:34:19 UTC) #7
On Mon, Jan 27, 2014 at 6:22 PM, <brettw@chromium.org> wrote:

> On 2014/01/27 19:42:26, Nico wrote:
>
>> What do you think about starting with system tests before doing changes
>> like
>> this first? Have a single test with a single hardcoded gyp and gn file
>> containing a single executable target with a single source file, build
>> both
>>
> gyp
>
>> file using gyp/ninja (and maybe gyp/xcode for ios) and gn file using gn's
>> gn->gyp->executable logic, compare produced executables for being
>> identical
>> would've been enough to find the majority of the issues the rollout found.
>>
>
> Really? I actually think it would have found none of them.


It would've found:
* NDEBUG not being defined
* Different -O flags
* I think the -arch flags (since re would've ended up with a fat binary and
gyp wouldn't)
* least some of the ios issues

I agree it wouldn't have found the goma issues. (I've converted the android
bots to use is_goma like devs do and have a CL in-flight to do this for the
non-android bots, so is_goma should be covered by bots by now.)


> The problem wasn't
> that there were flags subtly wrong in ways that are difficult to detect,
> but
> that I didn't know (and still don't) the scope of things to test and what
> flags
> people use. Like setting hardfp, -G output directories, mismatched
> make_global_settings due to differences in goma, etc. I don't even think
> doing
> what you describe would have found the multiple different -arch definition
> on
> Mac, since I don't think it can do both, and I don't think it would have
> linked
> at all if it had picked the "wrong one" (it linked on my configuration).
>
> https://codereview.chromium.org/141433015/
>

To unsubscribe from this group and stop receiving emails from it, send an email
to chromium-reviews+unsubscribe@chromium.org.

Powered by Google App Engine
This is Rietveld 408576698