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

Issue 10836080: ninja: make cross-compilation use $CC/$CXX for the target compiler (Closed)

Created:
8 years, 4 months ago by michaelbai
Modified:
8 years, 3 months ago
CC:
gyp-developer_googlegroups.com
Base URL:
http://git.chromium.org/external/gyp.git@master
Visibility:
Public.

Description

ninja: make cross-compilation use $CC/$CXX for the target compiler Took over from http://codereview.chromium.org/9649016/ BUG=140900 TEST=set CC/CXX to cross-compiler, set GYP_CROSSCOMPILE to 1, run gyp, ninja chrome.

Patch Set 1 #

Total comments: 2

Patch Set 2 : address comments #

Patch Set 3 : Fix mac #

Total comments: 2

Patch Set 4 : Used generator_supports_multiple_toolsets #

Total comments: 4

Patch Set 5 : Addressed comments #

Patch Set 6 : Fix mac bot #

Total comments: 2

Patch Set 7 : changed 'cc' #

Patch Set 8 : Fix the path issue #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+56 lines, -15 lines) Patch
M pylib/gyp/generator/ninja.py View 1 2 3 4 5 6 7 5 chunks +56 lines, -15 lines 2 comments Download

Messages

Total messages: 31 (0 generated)
michaelbai
8 years, 4 months ago (2012-08-02 18:39:27 UTC) #1
piman
http://codereview.chromium.org/10836080/diff/1/pylib/gyp/generator/ninja.py File pylib/gyp/generator/ninja.py (right): http://codereview.chromium.org/10836080/diff/1/pylib/gyp/generator/ninja.py#newcode1335 pylib/gyp/generator/ninja.py:1335: master_ninja.variable('ld_host', os.environ.get('LD_target', '$ld')) LD_host instead of LD_target
8 years, 4 months ago (2012-08-02 18:55:31 UTC) #2
Ami GONE FROM CHROMIUM
LGTM % piman's comment
8 years, 4 months ago (2012-08-02 19:23:17 UTC) #3
michaelbai
http://codereview.chromium.org/10836080/diff/1/pylib/gyp/generator/ninja.py File pylib/gyp/generator/ninja.py (right): http://codereview.chromium.org/10836080/diff/1/pylib/gyp/generator/ninja.py#newcode1335 pylib/gyp/generator/ninja.py:1335: master_ninja.variable('ld_host', os.environ.get('LD_target', '$ld')) On 2012/08/02 18:55:31, piman wrote: > ...
8 years, 4 months ago (2012-08-02 21:33:48 UTC) #4
piman
LGTM. Please send a PSA when this rolls.
8 years, 4 months ago (2012-08-02 21:47:01 UTC) #5
michaelbai
Committed revision 1448, will do DEPS ROLL tomorrow.
8 years, 4 months ago (2012-08-02 21:58:14 UTC) #6
michaelbai
As Nico's comment in http://codereview.chromium.org/9649016/, Using CC for cc_host in mac
8 years, 4 months ago (2012-08-03 18:15:27 UTC) #7
michaelbai
PTAL
8 years, 4 months ago (2012-08-03 18:15:39 UTC) #8
Nico
https://chromiumcodereview.appspot.com/10836080/diff/8001/pylib/gyp/generator/ninja.py File pylib/gyp/generator/ninja.py (right): https://chromiumcodereview.appspot.com/10836080/diff/8001/pylib/gyp/generator/ninja.py#newcode1311 pylib/gyp/generator/ninja.py:1311: # whatever CC was chrome/linux/clang also sets just CC. ...
8 years, 4 months ago (2012-08-03 18:17:18 UTC) #9
michaelbai
PTAL https://chromiumcodereview.appspot.com/10836080/diff/8001/pylib/gyp/generator/ninja.py File pylib/gyp/generator/ninja.py (right): https://chromiumcodereview.appspot.com/10836080/diff/8001/pylib/gyp/generator/ninja.py#newcode1311 pylib/gyp/generator/ninja.py:1311: # whatever CC was used generator_supports_multiple_toolsets to decide ...
8 years, 4 months ago (2012-08-06 18:26:28 UTC) #10
Nico
http://codereview.chromium.org/10836080/diff/11001/pylib/gyp/generator/ninja.py File pylib/gyp/generator/ninja.py (right): http://codereview.chromium.org/10836080/diff/11001/pylib/gyp/generator/ninja.py#newcode1309 pylib/gyp/generator/ninja.py:1309: cc_host, cxx_host = cc, cxx I'd set these to ...
8 years, 4 months ago (2012-08-06 19:17:44 UTC) #11
michaelbai
Changed the code as we discussed, PTAL http://codereview.chromium.org/10836080/diff/11001/pylib/gyp/generator/ninja.py File pylib/gyp/generator/ninja.py (right): http://codereview.chromium.org/10836080/diff/11001/pylib/gyp/generator/ninja.py#newcode1351 pylib/gyp/generator/ninja.py:1351: I will ...
8 years, 4 months ago (2012-08-06 23:04:23 UTC) #12
Nico
LGTM
8 years, 4 months ago (2012-08-06 23:44:36 UTC) #13
michaelbai
Committed as 1453, will roll deps now.
8 years, 4 months ago (2012-08-07 17:39:42 UTC) #14
michaelbai
Should fix mac bot error, PTAL
8 years, 4 months ago (2012-08-07 23:04:24 UTC) #15
Nico
https://chromiumcodereview.appspot.com/10836080/diff/11003/pylib/gyp/generator/ninja.py File pylib/gyp/generator/ninja.py (right): https://chromiumcodereview.appspot.com/10836080/diff/11003/pylib/gyp/generator/ninja.py#newcode1355 pylib/gyp/generator/ninja.py:1355: cc_host.replace('$(CC)', os.environ.get('CC', 'CC environment is not set')) Why not ...
8 years, 4 months ago (2012-08-07 23:07:14 UTC) #16
michaelbai
https://chromiumcodereview.appspot.com/10836080/diff/11003/pylib/gyp/generator/ninja.py File pylib/gyp/generator/ninja.py (right): https://chromiumcodereview.appspot.com/10836080/diff/11003/pylib/gyp/generator/ninja.py#newcode1355 pylib/gyp/generator/ninja.py:1355: cc_host.replace('$(CC)', os.environ.get('CC', 'CC environment is not set')) On 2012/08/07 ...
8 years, 4 months ago (2012-08-08 00:31:42 UTC) #17
Nico
lgtm
8 years, 4 months ago (2012-08-08 00:33:16 UTC) #18
michaelbai
Hi Nico, Could you take another look? the previous fix is not correct, both cc ...
8 years, 4 months ago (2012-08-08 17:33:47 UTC) #19
Nico
http://codereview.chromium.org/10836080/diff/11005/pylib/gyp/generator/ninja.py File pylib/gyp/generator/ninja.py (right): http://codereview.chromium.org/10836080/diff/11005/pylib/gyp/generator/ninja.py#newcode1362 pylib/gyp/generator/ninja.py:1362: cxx_host = cxx_host_global_setting.replace('$(CXX)', cxx) I understand that you need ...
8 years, 4 months ago (2012-08-08 17:36:10 UTC) #20
michaelbai
http://codereview.chromium.org/10836080/diff/11005/pylib/gyp/generator/ninja.py File pylib/gyp/generator/ninja.py (right): http://codereview.chromium.org/10836080/diff/11005/pylib/gyp/generator/ninja.py#newcode1362 pylib/gyp/generator/ninja.py:1362: cxx_host = cxx_host_global_setting.replace('$(CXX)', cxx) The cc_host_global_setting stores the raw ...
8 years, 4 months ago (2012-08-08 17:40:42 UTC) #21
Nico
lgtm Man, is this tricky :-/
8 years, 4 months ago (2012-08-08 17:52:40 UTC) #22
michaelbai
In my opinion, supporting ['CC.host', '$(CC)'] is kind of hack. If I don't know the ...
8 years, 4 months ago (2012-08-08 18:18:41 UTC) #23
Sam Clegg
On 2012/08/08 17:52:40, Nico wrote: > lgtm > > Man, is this tricky :-/ I ...
8 years, 4 months ago (2012-08-08 18:22:09 UTC) #24
Yaron
Funnily enough this seems to break the ninja build of android. $ head out/Release/build.ninja cc ...
8 years, 4 months ago (2012-08-10 17:36:36 UTC) #25
Nico
yes, CC / CXX is now the target compiler (to match make). It used to ...
8 years, 4 months ago (2012-08-10 17:48:01 UTC) #26
Yaron
On 2012/08/10 17:48:01, Nico wrote: > yes, CC / CXX is now the target compiler ...
8 years, 4 months ago (2012-08-10 17:52:38 UTC) #27
michaelbai
On 2012/08/10 17:52:38, Yaron wrote: > On 2012/08/10 17:48:01, Nico wrote: > > yes, CC ...
8 years, 4 months ago (2012-08-10 18:06:16 UTC) #28
Yaron
Ok, fair enough. Mailed http://codereview.chromium.org/10836192/ for Android
8 years, 4 months ago (2012-08-10 18:07:40 UTC) #29
Ami GONE FROM CHROMIUM
Can this bug be closed now? (I think it landed as http://code.google.com/p/gyp/source/detail?r=1463)
8 years, 4 months ago (2012-08-11 17:22:13 UTC) #30
Yaron
8 years, 3 months ago (2012-09-04 17:25:00 UTC) #31
On 2012/08/11 17:22:13, Ami Fischman wrote:
> Can this bug be closed now? (I think it landed as
> http://code.google.com/p/gyp/source/detail?r=1463)

Ya. I'm closing it and http://codereview.chromium.org/9649016/

Powered by Google App Engine
This is Rietveld 408576698