Chromium Code Reviews| Index: site_scons/site_tools/component_builders.py |
| diff --git a/site_scons/site_tools/component_builders.py b/site_scons/site_tools/component_builders.py |
| index f726919b3c86a2478e69c3608b4b68bc12f0257d..59d1d36adfaa91e8bd04840d0fea504f240ab049 100755 |
| --- a/site_scons/site_tools/component_builders.py |
| +++ b/site_scons/site_tools/component_builders.py |
| @@ -133,7 +133,10 @@ def _ComponentPlatformSetup(env, builder_name, **kwargs): |
| # approach allows us to use an unmodified version of SCons. |
| # In general, the use of EXTRA_LIBS is discouraged. |
| if 'EXTRA_LIBS' in env: |
| - env['LIBS'] = env['EXTRA_LIBS'] + env['LIBS'] |
| + # The SubstList2 method expands and flattens so that scons will |
| + # correctly know about the library dependencies in cases like |
| + # EXTRA_LIBS=['${FOO_LIBS}', 'bar']. |
| + env['LIBS'] = env.SubstList2('${EXTRA_LIBS}', '${LIBS}') |
| # Call platform-specific component setup function, if any |
| if env.get('COMPONENT_PLATFORM_SETUP'): |
| @@ -468,6 +471,12 @@ def ComponentProgram(self, prog_name, *args, **kwargs): |
| # Add dependencies on includes |
| env.Depends(out_nodes, env['INCLUDES']) |
|
robertm
2011/06/27 14:55:15
can you add some markers here to indicate that thi
|
| + # Add dependencies on libraries marked as implicitly included in the link. |
| + # These are libraries that are not passed on the command line, but are |
| + # always linked in by the toolchain, i.e. startup files and -lc and such. |
| + if 'IMPLICIT_LIBS' in env: |
| + env.Depends(out_nodes, env['IMPLICIT_LIBS']) |
| + |
| # Publish output |
| env.Publish(prog_name, 'run', out_nodes[0]) |
| env.Publish(prog_name, 'debug', out_nodes[1:]) |
| @@ -627,4 +636,3 @@ def generate(env): |
| AddTargetGroup('run_small_tests', 'small tests can be run') |
| AddTargetGroup('run_medium_tests', 'medium tests can be run') |
| AddTargetGroup('run_large_tests', 'large tests can be run') |
| - |