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

Issue 10909158: Add support for building targets directly from gyp. (Closed)

Created:
8 years, 3 months ago by Sam Clegg
Modified:
8 years, 3 months ago
Reviewers:
bradnelson, bradn
CC:
gyp-developer_googlegroups.com
Visibility:
Public.

Description

Add support for building targets directly from gyp. A new --build option has been added which can be used to build configurations directly from gyp. Each generator has a new method (PerformBuild) which knows how to invoke the underlying build environment to build a certain configuration. e.g. $ gyp hello.gyp --format=ninja --build=Default This allows gyp call sites to do actual builds without having to know the exact method for running the underlying build environment. The motivation here is to remove the complexity and duplication involved with building from gyp. Currently there are several places where gyp is run and then the underlying build is run right away in all cases. (e.g the Gyp tests, the buildbots). NaCl and the NaCL SDK are also about to add two more places where this is desirable. Rational for putting this logic in the generators themselves is that the generator maintainer is best placed to know how to invoke the build. Also the details of how to run Foo seem best placed in the Foo generator (especially if you think of generators as plugins for gyp). BUG= Committed: https://code.google.com/p/gyp/source/detail?r=1499

Patch Set 1 #

Patch Set 2 : add msvs #

Patch Set 3 : rebase #

Patch Set 4 : #

Patch Set 5 : #

Patch Set 6 : #

Patch Set 7 : #

Patch Set 8 : #

Total comments: 15

Patch Set 9 : fix nits #

Unified diffs Side-by-side diffs Delta from patch set Stats (+119 lines, -2 lines) Patch
M gyptest.py View 1 2 3 4 5 6 7 1 chunk +3 lines, -1 line 0 comments Download
M pylib/gyp/MSVSVersion.py View 1 2 3 4 5 6 7 8 5 chunks +13 lines, -0 lines 0 comments Download
M pylib/gyp/__init__.py View 1 2 3 4 5 6 7 8 2 chunks +9 lines, -0 lines 0 comments Download
M pylib/gyp/generator/make.py View 1 2 3 4 5 6 7 8 2 chunks +12 lines, -0 lines 0 comments Download
M pylib/gyp/generator/msvs.py View 1 2 3 4 5 6 7 8 2 chunks +20 lines, -0 lines 0 comments Download
M pylib/gyp/generator/ninja.py View 1 2 3 4 5 6 7 8 1 chunk +9 lines, -0 lines 0 comments Download
M pylib/gyp/generator/scons.py View 1 2 3 4 5 6 2 chunks +25 lines, -0 lines 0 comments Download
M pylib/gyp/generator/xcode.py View 1 chunk +19 lines, -0 lines 0 comments Download
A + test/build-option/gyptest-build.py View 1 chunk +1 line, -3 lines 0 comments Download
A + test/build-option/hello.c View 0 chunks +-1 lines, --1 lines 0 comments Download
A + test/build-option/hello.gyp View 0 chunks +-1 lines, --1 lines 0 comments Download
M test/lib/TestGyp.py View 1 2 3 4 5 6 7 8 2 chunks +10 lines, -0 lines 0 comments Download

Messages

Total messages: 5 (0 generated)
Sam Clegg
8 years, 3 months ago (2012-09-12 21:01:10 UTC) #1
Sam Clegg
On 2012/09/12 21:01:10, Sam Clegg wrote: Ok.. all trybots are now passing. I had to ...
8 years, 3 months ago (2012-09-13 23:05:40 UTC) #2
bradn
Cool LGTM wit nits http://codereview.chromium.org/10909158/diff/10024/pylib/gyp/MSVSVersion.py File pylib/gyp/MSVSVersion.py (right): http://codereview.chromium.org/10909158/diff/10024/pylib/gyp/MSVSVersion.py#newcode273 pylib/gyp/MSVSVersion.py:273: p = subprocess.Popen(["cygpath", path], stdout=subprocess.PIPE) ...
8 years, 3 months ago (2012-09-18 00:22:39 UTC) #3
Sam Clegg
http://codereview.chromium.org/10909158/diff/10024/pylib/gyp/MSVSVersion.py File pylib/gyp/MSVSVersion.py (right): http://codereview.chromium.org/10909158/diff/10024/pylib/gyp/MSVSVersion.py#newcode273 pylib/gyp/MSVSVersion.py:273: p = subprocess.Popen(["cygpath", path], stdout=subprocess.PIPE) On 2012/09/18 00:22:39, bradn ...
8 years, 3 months ago (2012-09-18 00:47:17 UTC) #4
bradn
8 years, 3 months ago (2012-09-18 16:18:31 UTC) #5
lgtm

Powered by Google App Engine
This is Rietveld 408576698