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: pylib/gyp/generator/make.py

Issue 9254033: xcode emulation for make: Adjust .a and .dylib entries in 'libraries'. (Closed) Base URL: http://gyp.googlecode.com/svn/trunk/
Patch Set: '' Created 8 years, 11 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 | pylib/gyp/generator/ninja.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 # Copyright (c) 2012 Google Inc. All rights reserved. 1 # Copyright (c) 2012 Google Inc. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 # Notes: 5 # Notes:
6 # 6 #
7 # This is all roughly based on the Makefile system used by the Linux 7 # This is all roughly based on the Makefile system used by the Linux
8 # kernel, but is a non-recursive make -- we put the entire dependency 8 # kernel, but is a non-recursive make -- we put the entire dependency
9 # graph in front of make and let it figure it out. 9 # graph in front of make and let it figure it out.
10 # 10 #
(...skipping 1411 matching lines...) Expand 10 before | Expand all | Expand 10 after
1422 # so we need lots of escaping. 1422 # so we need lots of escaping.
1423 ldflags.append(r'-Wl,-rpath=\$$ORIGIN/lib.%s/' % self.toolset) 1423 ldflags.append(r'-Wl,-rpath=\$$ORIGIN/lib.%s/' % self.toolset)
1424 ldflags.append(r'-Wl,-rpath-link=\$(builddir)/lib.%s/' % 1424 ldflags.append(r'-Wl,-rpath-link=\$(builddir)/lib.%s/' %
1425 self.toolset) 1425 self.toolset)
1426 self.WriteList(ldflags, 'LDFLAGS_%s' % configname) 1426 self.WriteList(ldflags, 'LDFLAGS_%s' % configname)
1427 libraries = spec.get('libraries') 1427 libraries = spec.get('libraries')
1428 if libraries: 1428 if libraries:
1429 # Remove duplicate entries 1429 # Remove duplicate entries
1430 libraries = gyp.common.uniquer(libraries) 1430 libraries = gyp.common.uniquer(libraries)
1431 if self.flavor == 'mac': 1431 if self.flavor == 'mac':
1432 libraries = self.xcode_settings.AdjustFrameworkLibraries(libraries) 1432 libraries = self.xcode_settings.AdjustLibraries(libraries)
1433 self.WriteList(libraries, 'LIBS') 1433 self.WriteList(libraries, 'LIBS')
1434 self.WriteLn('%s: GYP_LDFLAGS := $(LDFLAGS_$(BUILDTYPE))' % 1434 self.WriteLn('%s: GYP_LDFLAGS := $(LDFLAGS_$(BUILDTYPE))' %
1435 QuoteSpaces(self.output_binary)) 1435 QuoteSpaces(self.output_binary))
1436 self.WriteLn('%s: LIBS := $(LIBS)' % QuoteSpaces(self.output_binary)) 1436 self.WriteLn('%s: LIBS := $(LIBS)' % QuoteSpaces(self.output_binary))
1437 1437
1438 postbuilds = [] 1438 postbuilds = []
1439 if self.flavor == 'mac': 1439 if self.flavor == 'mac':
1440 if target_postbuilds: 1440 if target_postbuilds:
1441 postbuilds.append('$(TARGET_POSTBUILDS_$(BUILDTYPE))') 1441 postbuilds.append('$(TARGET_POSTBUILDS_$(BUILDTYPE))')
1442 # Postbuild actions. Like actions, but implicitly depend on the target's 1442 # Postbuild actions. Like actions, but implicitly depend on the target's
(...skipping 733 matching lines...) Expand 10 before | Expand all | Expand 10 after
2176 # Add a check to make sure we tried to process all the .d files. 2176 # Add a check to make sure we tried to process all the .d files.
2177 all_deps += """ 2177 all_deps += """
2178 ifneq ($(word %(last)d,$(d_files)),) 2178 ifneq ($(word %(last)d,$(d_files)),)
2179 $(error Found unprocessed dependency files (gyp didn't generate enough rules !)) 2179 $(error Found unprocessed dependency files (gyp didn't generate enough rules !))
2180 endif 2180 endif
2181 """ % { 'last': ((num_outputs / 1000) + 1) * 1000 + 1 } 2181 """ % { 'last': ((num_outputs / 1000) + 1) * 1000 + 1 }
2182 2182
2183 root_makefile.write(SHARED_FOOTER % { 'generate_all_deps': all_deps }) 2183 root_makefile.write(SHARED_FOOTER % { 'generate_all_deps': all_deps })
2184 2184
2185 root_makefile.close() 2185 root_makefile.close()
OLDNEW
« no previous file with comments | « no previous file | pylib/gyp/generator/ninja.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698