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

Side by Side Diff: test/mac/gyptest-lto.py

Issue 1057723002: Address scottmg comments from https://codereview.chromium.org/1003273007/. (Closed) Base URL: https://chromium.googlesource.com/external/gyp.git@master
Patch Set: Created 5 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 | « no previous file | test/mac/lto/test.gyp » ('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) 2015 Google Inc. All rights reserved. 3 # Copyright (c) 2015 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 LTO flags work. 8 Verifies that LTO flags work.
9 """ 9 """
10 10
11 import TestGyp 11 import TestGyp
12 12
13 import os 13 import os
14 import re 14 import re
15 import subprocess 15 import subprocess
16 import sys 16 import sys
17 17
18 if sys.platform == 'darwin': 18 if sys.platform == 'darwin':
19 test = TestGyp.TestGyp(formats=['ninja', 'make', 'xcode']) 19 test = TestGyp.TestGyp(formats=['ninja', 'make', 'xcode'])
20 #if test.format == 'xcode-ninja':
21 # test.skip_test()
22 CHDIR = 'lto' 20 CHDIR = 'lto'
23 test.run_gyp('test.gyp', chdir=CHDIR) 21 test.run_gyp('test.gyp', chdir=CHDIR)
24 22
25 test.build('test.gyp', test.ALL, chdir=CHDIR) 23 test.build('test.gyp', test.ALL, chdir=CHDIR)
26 24
27 def ObjPath(srcpath, target): 25 def ObjPath(srcpath, target):
28 # TODO: Move this into TestGyp if it's needed elsewhere. 26 # TODO: Move this into TestGyp if it's needed elsewhere.
29 if test.format == 'xcode': 27 if test.format == 'xcode':
30 return os.path.join(CHDIR, 'build', 'test.build', 'Default', 28 return os.path.join(CHDIR, 'build', 'test.build', 'Default',
31 target + '.build', 'Objects-normal', 'x86_64', 29 target + '.build', 'Objects-normal', 'x86_64',
(...skipping 26 matching lines...) Expand all
58 ObjType(ObjPath('cfile', 'lto_static'), 'llvm') 56 ObjType(ObjPath('cfile', 'lto_static'), 'llvm')
59 ObjType(ObjPath('ccfile', 'lto_static'), 'llvm') 57 ObjType(ObjPath('ccfile', 'lto_static'), 'llvm')
60 ObjType(ObjPath('mfile', 'lto_static'), 'llvm') 58 ObjType(ObjPath('mfile', 'lto_static'), 'llvm')
61 ObjType(ObjPath('mmfile', 'lto_static'), 'llvm') 59 ObjType(ObjPath('mmfile', 'lto_static'), 'llvm')
62 ObjType(ObjPath('asmfile', 'lto_static'), 'mach-o') 60 ObjType(ObjPath('asmfile', 'lto_static'), 'mach-o')
63 61
64 test.pass_test() 62 test.pass_test()
65 63
66 # TODO: Probably test for -object_path_lto too, else dsymutil won't be 64 # TODO: Probably test for -object_path_lto too, else dsymutil won't be
67 # useful maybe? 65 # useful maybe?
OLDNEW
« no previous file with comments | « no previous file | test/mac/lto/test.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698