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

Side by Side Diff: test/toolsets/gyptest-toolsets.py

Issue 13992005: Fix rpath for components when cross-compiling. (Closed) Base URL: https://chromium.googlesource.com/external/gyp.git@master
Patch Set: linux-only Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « pylib/gyp/generator/ninja.py ('k') | test/toolsets/main.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 2
3 # Copyright (c) 2009 Google Inc. All rights reserved. 3 # Copyright (c) 2009 Google Inc. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 6
7 """ 7 """
8 Verifies that toolsets are correctly applied 8 Verifies that toolsets are correctly applied
9 """ 9 """
10 10 import os
11 import sys
11 import TestGyp 12 import TestGyp
12 13
13 # Multiple toolsets are currently only supported by the make generator. 14 if sys.platform.startswith('linux'):
14 test = TestGyp.TestGyp(formats=['make'])
15 15
16 test.run_gyp('toolsets.gyp') 16 test = TestGyp.TestGyp(formats=['make', 'ninja'])
17 17
18 test.build('toolsets.gyp', test.ALL) 18 oldenv = os.environ.copy()
19 try:
20 os.environ['GYP_CROSSCOMPILE'] = '1'
21 test.run_gyp('toolsets.gyp')
22 finally:
23 os.environ.clear()
24 os.environ.update(oldenv)
19 25
20 test.run_built_executable('host-main', stdout="Host\n") 26 test.build('toolsets.gyp', test.ALL)
21 test.run_built_executable('target-main', stdout="Target\n")
22 27
23 test.pass_test() 28 test.run_built_executable('host-main', stdout="Host\nShared: Host\n")
29 test.run_built_executable('target-main', stdout="Target\nShared: Target\n")
30
31 test.pass_test()
OLDNEW
« no previous file with comments | « pylib/gyp/generator/ninja.py ('k') | test/toolsets/main.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698