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

Unified Diff: pylib/gyp/generator/scons.py

Issue 67207: Remove "static" files from the input list to fix the chromium shared build. (Closed) Base URL: http://gyp.googlecode.com/svn/trunk/
Patch Set: Created 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pylib/gyp/generator/scons.py
===================================================================
--- pylib/gyp/generator/scons.py (revision 428)
+++ pylib/gyp/generator/scons.py (working copy)
@@ -364,7 +364,12 @@
'message' : message,
})
if rule.get('process_outputs_as_sources'):
- fp.write(' input_files.Replace(%s_file, _outputs)\n' % name)
+ # Remove header files so we don't add them to inputs and try to link them.
+ fp.write(' linkable_files = [f for f in _outputs if not str(f).endswith(\'.h\')]\n')
+ fp.write(' input_files.Replace(%s_file, linkable_files)\n' % name)
+ else:
+ # Remove the source file e.g. the gperf file to avoid trying to link it.
+ fp.write(' input_files.Remove(%s_file)\n' % name)
fp.write('prerequisites.extend(_outputs)\n')
SConsTypeWriter[spec.get('type')](fp, spec)
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698