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

Unified Diff: SConstruct

Issue 11000: Periodic merge of bleeding_edge to experimental code generator branch.... (Closed) Base URL: http://v8.googlecode.com/svn/branches/experimental/toiger/
Patch Set: Created 12 years, 1 month 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 | « ChangeLog ('k') | include/v8-debug.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: SConstruct
===================================================================
--- SConstruct (revision 868)
+++ SConstruct (working copy)
@@ -54,6 +54,9 @@
'mode:release': {
'CCFLAGS': ['-O3', '-fomit-frame-pointer']
},
+ 'os:freebsd': {
+ 'LIBS': ['execinfo']
+ },
'wordsize:64': {
'CCFLAGS': ['-m32'],
'LINKFLAGS': ['-m32']
@@ -71,15 +74,27 @@
'CCPDBFLAGS': ['/Zi']
},
'mode:debug': {
- 'CCFLAGS': ['/Od', '/Gm', '/MTd'],
+ 'CCFLAGS': ['/Od', '/Gm'],
'CPPDEFINES': ['_DEBUG', 'ENABLE_DISASSEMBLER', 'DEBUG'],
- 'LINKFLAGS': ['/DEBUG']
+ 'LINKFLAGS': ['/DEBUG'],
+ 'msvcrt:static': {
+ 'CCFLAGS': ['/MTd']
+ },
+ 'msvcrt:shared': {
+ 'CCFLAGS': ['/MDd']
+ }
},
'mode:release': {
- 'CCFLAGS': ['/O2', '/MT', '/GL'],
+ 'CCFLAGS': ['/O2', '/GL'],
'LINKFLAGS': ['/OPT:REF', '/OPT:ICF', '/LTCG'],
- 'ARFLAGS': ['/LTCG']
- }
+ 'ARFLAGS': ['/LTCG'],
+ 'msvcrt:static': {
+ 'CCFLAGS': ['/MT']
+ },
+ 'msvcrt:shared': {
+ 'CCFLAGS': ['/MD']
+ }
+ },
}
}
@@ -186,6 +201,9 @@
'LIBS': ['pthread'],
'LIBPATH': ['.']
},
+ 'os:freebsd': {
+ 'LIBS': ['execinfo']
+ },
'wordsize:64': {
'CCFLAGS': ['-m32'],
'LINKFLAGS': ['-m32']
@@ -209,12 +227,24 @@
'LINKFLAGS': ['/MAP']
},
'mode:release': {
- 'CCFLAGS': ['/O2', '/MT'],
- 'LINKFLAGS': ['/OPT:REF', '/OPT:ICF', '/LTCG']
+ 'CCFLAGS': ['/O2'],
+ 'LINKFLAGS': ['/OPT:REF', '/OPT:ICF', '/LTCG'],
+ 'msvcrt:static': {
+ 'CCFLAGS': ['/MT']
+ },
+ 'msvcrt:shared': {
+ 'CCFLAGS': ['/MD']
+ }
},
'mode:debug': {
- 'CCFLAGS': ['/Od', '/MTd'],
- 'LINKFLAGS': ['/DEBUG']
+ 'CCFLAGS': ['/Od'],
+ 'LINKFLAGS': ['/DEBUG'],
+ 'msvcrt:static': {
+ 'CCFLAGS': ['/MTd']
+ },
+ 'msvcrt:shared': {
+ 'CCFLAGS': ['/MDd']
+ }
}
}
}
@@ -226,7 +256,6 @@
'LIBS': ['readline']
}
},
- 'msvc': { }
}
@@ -264,7 +293,7 @@
'help': 'the toolchain to use'
},
'os': {
- 'values': ['linux', 'macos', 'win32'],
+ 'values': ['freebsd', 'linux', 'macos', 'win32'],
'default': OS_GUESS,
'help': 'the os to build for'
},
@@ -288,6 +317,11 @@
'default': 'static',
'help': 'the type of library to produce'
},
+ 'msvcrt': {
+ 'values': ['static', 'shared'],
+ 'default': 'static',
+ 'help': 'the type of MSVCRT library to use'
+ },
'wordsize': {
'values': ['64', '32'],
'default': WORDSIZE_GUESS,
@@ -375,11 +409,18 @@
result = initial.copy()
self.AppendFlags(result, flags.get('all'))
toolchain = self.options['toolchain']
- self.AppendFlags(result, flags[toolchain].get('all'))
+ if toolchain in flags:
+ self.AppendFlags(result, flags[toolchain].get('all'))
+ for option in sorted(self.options.keys()):
+ value = self.options[option]
+ self.AppendFlags(result, flags[toolchain].get(option + ':' + value))
+ return result
+
+ def AddRelevantSubFlags(self, options, flags):
+ self.AppendFlags(options, flags.get('all'))
for option in sorted(self.options.keys()):
value = self.options[option]
- self.AppendFlags(result, flags[toolchain].get(option + ':' + value))
- return result
+ self.AppendFlags(options, flags.get(option + ':' + value))
def GetRelevantSources(self, source):
result = []
@@ -392,12 +433,15 @@
if not added:
return
for (key, value) in added.iteritems():
- if not key in options:
- options[key] = value
+ if key.find(':') != -1:
+ self.AddRelevantSubFlags(options, { key: value })
else:
- prefix = options[key]
- if isinstance(prefix, StringTypes): prefix = prefix.split()
- options[key] = prefix + value
+ if not key in options:
+ options[key] = value
+ else:
+ prefix = options[key]
+ if isinstance(prefix, StringTypes): prefix = prefix.split()
+ options[key] = prefix + value
def ConfigureObject(self, env, input, **kw):
if self.options['library'] == 'static':
@@ -541,7 +585,7 @@
env.Alias('cctests', cctests)
env.Alias('sample', samples)
env.Alias('d8', d8s)
-
+
if env['sample']:
env.Default('sample')
else:
« no previous file with comments | « ChangeLog ('k') | include/v8-debug.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698