v8_external_snapshot target visible only when using v8_use_external_startup_data
Prevent snapshot_blob.bin from being unnecessarily generated when building all targets. When such file exists, chrome_tests assumes we will load V8's initial snapshot from external files, even when such feature is turned off, which prevents the tests from being successfully compiled. BUG=421063 LOG=N R=rmcilroy@chromium.org Review URL: https://codereview.chromium.org/643163002 Patch from André Baixo <baixo@google.com>. git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24550 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
3dae2a0d3f
commit
03f4956744
146
tools/gyp/v8.gyp
146
tools/gyp/v8.gyp
@ -229,56 +229,65 @@
|
||||
'target_name': 'v8_external_snapshot',
|
||||
'type': 'static_library',
|
||||
'conditions': [
|
||||
['want_separate_host_toolset==1', {
|
||||
'toolsets': ['host', 'target'],
|
||||
'dependencies': [
|
||||
'mksnapshot#host',
|
||||
'js2c#host',
|
||||
'natives_blob',
|
||||
]}, {
|
||||
'toolsets': ['target'],
|
||||
'dependencies': [
|
||||
'mksnapshot',
|
||||
'js2c',
|
||||
'natives_blob',
|
||||
],
|
||||
}],
|
||||
['component=="shared_library"', {
|
||||
'defines': [
|
||||
'V8_SHARED',
|
||||
'BUILDING_V8_SHARED',
|
||||
],
|
||||
'direct_dependent_settings': {
|
||||
'defines': [
|
||||
'V8_SHARED',
|
||||
'USING_V8_SHARED',
|
||||
],
|
||||
},
|
||||
}],
|
||||
],
|
||||
'dependencies': [
|
||||
'v8_base',
|
||||
],
|
||||
'include_dirs+': [
|
||||
'../..',
|
||||
],
|
||||
'sources': [
|
||||
'../../src/natives-external.cc',
|
||||
'../../src/snapshot-external.cc',
|
||||
],
|
||||
'actions': [
|
||||
{
|
||||
'action_name': 'run_mksnapshot (external)',
|
||||
'inputs': [
|
||||
'<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot<(EXECUTABLE_SUFFIX)',
|
||||
],
|
||||
[ 'v8_use_external_startup_data==1', {
|
||||
'conditions': [
|
||||
['want_separate_host_toolset==1', {
|
||||
'target_conditions': [
|
||||
['_toolset=="host"', {
|
||||
'outputs': [
|
||||
'<(INTERMEDIATE_DIR)/snapshot.cc',
|
||||
'<(PRODUCT_DIR)/snapshot_blob_host.bin',
|
||||
'toolsets': ['host', 'target'],
|
||||
'dependencies': [
|
||||
'mksnapshot#host',
|
||||
'js2c#host',
|
||||
'natives_blob',
|
||||
]}, {
|
||||
'toolsets': ['target'],
|
||||
'dependencies': [
|
||||
'mksnapshot',
|
||||
'js2c',
|
||||
'natives_blob',
|
||||
],
|
||||
}],
|
||||
['component=="shared_library"', {
|
||||
'defines': [
|
||||
'V8_SHARED',
|
||||
'BUILDING_V8_SHARED',
|
||||
],
|
||||
'direct_dependent_settings': {
|
||||
'defines': [
|
||||
'V8_SHARED',
|
||||
'USING_V8_SHARED',
|
||||
],
|
||||
},
|
||||
}],
|
||||
],
|
||||
'dependencies': [
|
||||
'v8_base',
|
||||
],
|
||||
'include_dirs+': [
|
||||
'../..',
|
||||
],
|
||||
'sources': [
|
||||
'../../src/natives-external.cc',
|
||||
'../../src/snapshot-external.cc',
|
||||
],
|
||||
'actions': [
|
||||
{
|
||||
'action_name': 'run_mksnapshot (external)',
|
||||
'inputs': [
|
||||
'<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)mksnapshot<(EXECUTABLE_SUFFIX)',
|
||||
],
|
||||
'conditions': [
|
||||
['want_separate_host_toolset==1', {
|
||||
'target_conditions': [
|
||||
['_toolset=="host"', {
|
||||
'outputs': [
|
||||
'<(INTERMEDIATE_DIR)/snapshot.cc',
|
||||
'<(PRODUCT_DIR)/snapshot_blob_host.bin',
|
||||
],
|
||||
}, {
|
||||
'outputs': [
|
||||
'<(INTERMEDIATE_DIR)/snapshot.cc',
|
||||
'<(PRODUCT_DIR)/snapshot_blob.bin',
|
||||
],
|
||||
}],
|
||||
],
|
||||
}, {
|
||||
'outputs': [
|
||||
@ -287,31 +296,26 @@
|
||||
],
|
||||
}],
|
||||
],
|
||||
}, {
|
||||
'outputs': [
|
||||
'<(INTERMEDIATE_DIR)/snapshot.cc',
|
||||
'<(PRODUCT_DIR)/snapshot_blob.bin',
|
||||
'variables': {
|
||||
'mksnapshot_flags': [
|
||||
'--log-snapshot-positions',
|
||||
'--logfile', '<(INTERMEDIATE_DIR)/snapshot.log',
|
||||
],
|
||||
'conditions': [
|
||||
['v8_random_seed!=0', {
|
||||
'mksnapshot_flags': ['--random-seed', '<(v8_random_seed)'],
|
||||
}],
|
||||
],
|
||||
},
|
||||
'action': [
|
||||
'<@(_inputs)',
|
||||
'<@(mksnapshot_flags)',
|
||||
'<@(INTERMEDIATE_DIR)/snapshot.cc',
|
||||
'--startup_blob', '<(PRODUCT_DIR)/snapshot_blob.bin',
|
||||
],
|
||||
}],
|
||||
},
|
||||
],
|
||||
'variables': {
|
||||
'mksnapshot_flags': [
|
||||
'--log-snapshot-positions',
|
||||
'--logfile', '<(INTERMEDIATE_DIR)/snapshot.log',
|
||||
],
|
||||
'conditions': [
|
||||
['v8_random_seed!=0', {
|
||||
'mksnapshot_flags': ['--random-seed', '<(v8_random_seed)'],
|
||||
}],
|
||||
],
|
||||
},
|
||||
'action': [
|
||||
'<@(_inputs)',
|
||||
'<@(mksnapshot_flags)',
|
||||
'<@(INTERMEDIATE_DIR)/snapshot.cc',
|
||||
'--startup_blob', '<(PRODUCT_DIR)/snapshot_blob.bin',
|
||||
],
|
||||
},
|
||||
}],
|
||||
],
|
||||
},
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user