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

Side by Side Diff: src/native_client/site_scons/site_init.py

Issue 6719038: Revert r4644, "Updated NaCl's build system to use SCons 2.0.1." (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client
Patch Set: Created 9 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 | Annotate | Revision Log
OLDNEW
1 #!/usr/bin/python2.4 1 #!/usr/bin/python2.4
2 # Copyright 2009, Google Inc. 2 # Copyright 2009, Google Inc.
3 # All rights reserved. 3 # All rights reserved.
4 # 4 #
5 # Redistribution and use in source and binary forms, with or without 5 # Redistribution and use in source and binary forms, with or without
6 # modification, are permitted provided that the following conditions are 6 # modification, are permitted provided that the following conditions are
7 # met: 7 # met:
8 # 8 #
9 # * Redistributions of source code must retain the above copyright 9 # * Redistributions of source code must retain the above copyright
10 # notice, this list of conditions and the following disclaimer. 10 # notice, this list of conditions and the following disclaimer.
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 # directory. When we are passed a SConscript that is already under 111 # directory. When we are passed a SConscript that is already under
112 # $TARGET_ROOT, we should not use build_dir. 112 # $TARGET_ROOT, we should not use build_dir.
113 ec.SConscript(c_script, exports={'env': ec}, duplicate=0) 113 ec.SConscript(c_script, exports={'env': ec}, duplicate=0)
114 elif not ec.RelativePath('$MAIN_DIR', c_dir).startswith('..'): 114 elif not ec.RelativePath('$MAIN_DIR', c_dir).startswith('..'):
115 # The above expression means: if c_dir is $MAIN_DIR or anything 115 # The above expression means: if c_dir is $MAIN_DIR or anything
116 # under it. Going from c_dir to $TARGET_ROOT and dropping the not fails 116 # under it. Going from c_dir to $TARGET_ROOT and dropping the not fails
117 # to include $MAIN_DIR. 117 # to include $MAIN_DIR.
118 # Also, if we are passed a SConscript that 118 # Also, if we are passed a SConscript that
119 # is not under $MAIN_DIR, we should fail loudly, because it is unclear how 119 # is not under $MAIN_DIR, we should fail loudly, because it is unclear how
120 # this will correspond to things under $OBJ_ROOT. 120 # this will correspond to things under $OBJ_ROOT.
121 ec.SConscript(c_script, variant_dir='$OBJ_ROOT/' + c_dir, 121 ec.SConscript(c_script, build_dir='$OBJ_ROOT/' + c_dir,
122 exports={'env': ec}, duplicate=0) 122 exports={'env': ec}, duplicate=0)
123 else: 123 else:
124 raise SCons.Error.UserError( 124 raise SCons.Error.UserError(
125 'Bad location for a SConscript. "%s" is not under ' 125 'Bad location for a SConscript. "%s" is not under '
126 '\$TARGET_ROOT or \$MAIN_DIR' % c_script) 126 '\$TARGET_ROOT or \$MAIN_DIR' % c_script)
127 127
128 def FilterEnvironments(environments): 128 def FilterEnvironments(environments):
129 """Filters out the environments to be actually build from the specified list 129 """Filters out the environments to be actually build from the specified list
130 130
131 Args: 131 Args:
(...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after
358 # Since our site dir was specified on the SCons command line, SCons will 358 # Since our site dir was specified on the SCons command line, SCons will
359 # normally only look at our site dir. Add back checking for project-local 359 # normally only look at our site dir. Add back checking for project-local
360 # site_scons directories. 360 # site_scons directories.
361 if not SCons.Script.GetOption('no_site_dir'): 361 if not SCons.Script.GetOption('no_site_dir'):
362 SCons.Script.Main._load_site_scons_dir( 362 SCons.Script.Main._load_site_scons_dir(
363 SCons.Node.FS.get_default_fs().SConstruct_dir, None) 363 SCons.Node.FS.get_default_fs().SConstruct_dir, None)
364 364
365 365
366 # Run main code 366 # Run main code
367 SiteInitMain() 367 SiteInitMain()
OLDNEW
« no previous file with comments | « src/native_client/scons.bat ('k') | src/native_client/site_scons/site_tools/component_builders.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698