v8/gypfiles/d8.gyp
Yang Guo f9934aa9cf [gyp] move gyp files from src to gypfiles.
Bug: v8:7341
Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng;master.tryserver.blink:linux_trusty_blink_rel
Change-Id: I90879be3a94745859b7da7c9bb9b6533af11cc2d
Reviewed-on: https://chromium-review.googlesource.com/878221
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#50790}
2018-01-23 09:54:36 +00:00

139 lines
3.3 KiB
Python

# Copyright 2018 the V8 project authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
{
'variables': {
'v8_code': 1,
# Enable support for Intel VTune. Supported on ia32/x64 only
'v8_enable_vtunejit%': 0,
'v8_enable_i18n_support%': 1,
},
'includes': ['toolchain.gypi', 'features.gypi'],
'targets': [
{
'target_name': 'd8',
'type': 'executable',
'dependencies': [
'v8.gyp:v8',
'v8.gyp:v8_libbase',
'v8.gyp:v8_libplatform',
],
# Generated source files need this explicitly:
'include_dirs+': [
'..',
'<(DEPTH)',
],
'sources': [
'../src/d8.h',
'../src/d8.cc',
'../src/d8-console.h',
'../src/d8-console.cc',
'<(SHARED_INTERMEDIATE_DIR)/d8-js.cc',
],
'conditions': [
[ 'want_separate_host_toolset==1', {
'toolsets': [ 'target', ],
'dependencies': [
'd8_js2c#host',
],
}, {
'dependencies': [
'd8_js2c',
],
}],
['(OS=="linux" or OS=="mac" or OS=="freebsd" or OS=="netbsd" \
or OS=="openbsd" or OS=="solaris" or OS=="android" \
or OS=="qnx" or OS=="aix")', {
'sources': [ '../src/d8-posix.cc', ]
}],
[ 'OS=="win"', {
'sources': [ '../src/d8-windows.cc', ]
}],
[ 'component!="shared_library"', {
'conditions': [
[ 'v8_postmortem_support=="true"', {
'xcode_settings': {
'OTHER_LDFLAGS': [
'-Wl,-force_load,<(PRODUCT_DIR)/libv8_base.a'
],
},
}],
],
}],
['v8_enable_vtunejit==1', {
'dependencies': [
'v8vtune.gyp:v8_vtune',
],
}],
['v8_enable_i18n_support==1', {
'dependencies': [
'<(icu_gyp_path):icui18n',
'<(icu_gyp_path):icuuc',
],
}],
['OS=="win" and v8_enable_i18n_support==1', {
'dependencies': [
'<(icu_gyp_path):icudata',
],
}],
],
},
{
'target_name': 'd8_js2c',
'type': 'none',
'variables': {
'js_files': [
'../src/d8.js',
'../src/js/macros.py',
],
},
'conditions': [
[ 'want_separate_host_toolset==1', {
'toolsets': ['host'],
}, {
'toolsets': ['target'],
}]
],
'actions': [
{
'action_name': 'd8_js2c',
'inputs': [
'../tools/js2c.py',
'<@(js_files)',
],
'outputs': [
'<(SHARED_INTERMEDIATE_DIR)/d8-js.cc',
],
'action': [
'python',
'../tools/js2c.py',
'<@(_outputs)',
'D8',
'<@(js_files)'
],
},
],
},
],
'conditions': [
['test_isolation_mode != "noop"', {
'targets': [
{
'target_name': 'd8_run',
'type': 'none',
'dependencies': [
'd8',
],
'includes': [
'isolate.gypi',
],
'sources': [
'../src/d8.isolate',
],
},
],
}],
],
}