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

Side by Side Diff: native_client_sdk/src/build_tools/build_projects.py

Issue 15017017: [NaCl SDK] Before bundling, clean all built libraries. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: parallel builds Created 7 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | native_client_sdk/src/build_tools/build_sdk.py » ('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 # Copyright (c) 2013 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2013 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 5
6 import optparse 6 import optparse
7 import os 7 import os
8 import sys 8 import sys
9 9
10 import buildbot_common 10 import buildbot_common
(...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after
140 # We need to modify the environment to build host on Windows. 140 # We need to modify the environment to build host on Windows.
141 make = os.path.join(make_dir, 'make.bat') 141 make = os.path.join(make_dir, 'make.bat')
142 else: 142 else:
143 make = 'make' 143 make = 'make'
144 144
145 extra_args = ['CONFIG='+config] 145 extra_args = ['CONFIG='+config]
146 if not deps: 146 if not deps:
147 extra_args += ['IGNORE_DEPS=1'] 147 extra_args += ['IGNORE_DEPS=1']
148 148
149 try: 149 try:
150 buildbot_common.Run([make, '-j8', 'all_versions'] + extra_args, 150 buildbot_common.Run([make, '-j8', 'TOOLCHAIN=all'] + extra_args,
151 cwd=make_dir) 151 cwd=make_dir)
152 except: 152 except:
153 print 'Failed to build ' + branch 153 print 'Failed to build ' + branch
154 raise 154 raise
155 155
156 if clean: 156 if clean:
157 # Clean to remove temporary files but keep the built 157 # Clean to remove temporary files but keep the built
158 buildbot_common.Run([make, '-j8', 'clean'] + extra_args, 158 buildbot_common.Run([make, '-j8', 'clean', 'TOOLCHAIN=all'] + extra_args,
159 cwd=make_dir) 159 cwd=make_dir)
160 160
161 161
162 def BuildProjects(pepperdir, platform, project_tree, deps=True, 162 def BuildProjects(pepperdir, platform, project_tree, deps=True,
163 clean=False, config='Debug'): 163 clean=False, config='Debug'):
164 # First build libraries 164 # First build libraries
165 build_order = ['src', 'testlibs'] 165 build_order = ['src', 'testlibs']
166 for branch in build_order: 166 for branch in build_order:
167 if branch in project_tree: 167 if branch in project_tree:
168 BuildProjectsBranch(pepperdir, platform, branch, deps, clean, config) 168 BuildProjectsBranch(pepperdir, platform, branch, deps, clean, config)
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
215 print 'Filter by toolchain: ' + str(options.toolchain) 215 print 'Filter by toolchain: ' + str(options.toolchain)
216 if not options.experimental: 216 if not options.experimental:
217 filters['EXPERIMENTAL'] = False 217 filters['EXPERIMENTAL'] = False
218 if options.dest: 218 if options.dest:
219 filters['DEST'] = options.dest 219 filters['DEST'] = options.dest
220 print 'Filter by type: ' + str(options.dest) 220 print 'Filter by type: ' + str(options.dest)
221 if options.project: 221 if options.project:
222 filters['NAME'] = options.project 222 filters['NAME'] = options.project
223 print 'Filter by name: ' + str(options.project) 223 print 'Filter by name: ' + str(options.project)
224 224
225 project_tree = parse_dsc.LoadProjectTree(SDK_SRC_DIR, verbose=options.verbose, 225 project_tree = parse_dsc.LoadProjectTree(SDK_SRC_DIR, filters=filters)
226 filters=filters)
227 parse_dsc.PrintProjectTree(project_tree) 226 parse_dsc.PrintProjectTree(project_tree)
228 227
229 UpdateHelpers(pepperdir, platform, clobber=options.clobber) 228 UpdateHelpers(pepperdir, platform, clobber=options.clobber)
230 UpdateProjects(pepperdir, platform, project_tree, options.toolchain, 229 UpdateProjects(pepperdir, platform, project_tree, options.toolchain,
231 clobber=options.clobber) 230 clobber=options.clobber)
232 if options.build: 231 if options.build:
233 BuildProjects(pepperdir, platform, project_tree) 232 BuildProjects(pepperdir, platform, project_tree)
234 return 0 233 return 0
235 234
236 235
237 if __name__ == '__main__': 236 if __name__ == '__main__':
238 sys.exit(main(sys.argv)) 237 sys.exit(main(sys.argv))
OLDNEW
« no previous file with comments | « no previous file | native_client_sdk/src/build_tools/build_sdk.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698