mirror of
https://github.com/denoland/rusty_v8.git
synced 2024-11-21 20:28:58 +00:00
chore: clean up and remove redundant gn args (#981)
This commit is contained in:
parent
9cc57eb44d
commit
a9567bc31a
29
.gn
29
.gn
@ -17,27 +17,26 @@ check_targets = []
|
||||
secondary_source = "//v8/"
|
||||
|
||||
default_args = {
|
||||
clang_use_chrome_plugins = false
|
||||
is_component_build = false
|
||||
linux_use_bundled_binutils = false
|
||||
use_sysroot = false
|
||||
|
||||
use_dummy_lastchange = true
|
||||
treat_warnings_as_errors = true
|
||||
use_sysroot = false
|
||||
win_crt_flavor_agnostic = true
|
||||
|
||||
# Minimize size of debuginfo in distributed static library.
|
||||
no_inline_line_tables = true
|
||||
symbol_level = 1
|
||||
|
||||
v8_enable_snapshot_compression = false
|
||||
v8_enable_javascript_promise_hooks = true
|
||||
v8_promise_internal_field_count = 1
|
||||
v8_use_external_startup_data = false
|
||||
v8_use_snapshot = true
|
||||
|
||||
# To avoid test failure:
|
||||
# Fatal error in ../../../v8/src/heap/read-only-spaces.cc, line 69
|
||||
# Check failed: read_only_blob_checksum_ == snapshot_checksum (<unprintable>
|
||||
# vs. 604745897).
|
||||
v8_enable_shared_ro_heap = false
|
||||
|
||||
# https://cs.chromium.org/chromium/src/docs/ccache_mac.md
|
||||
clang_use_chrome_plugins = false
|
||||
v8_monolithic = false
|
||||
v8_enable_snapshot_compression = false
|
||||
v8_enable_javascript_promise_hooks = true
|
||||
v8_promise_internal_field_count = 1
|
||||
v8_use_external_startup_data = false
|
||||
v8_use_snapshot = true
|
||||
is_component_build = false
|
||||
win_crt_flavor_agnostic = true
|
||||
symbol_level = 1
|
||||
}
|
||||
|
4
BUILD.gn
4
BUILD.gn
@ -42,8 +42,4 @@ config("rusty_v8_config") {
|
||||
"-fansi-escape-codes",
|
||||
]
|
||||
}
|
||||
|
||||
if (is_debug && is_clang && !is_win) {
|
||||
cflags += [ "-glldb" ]
|
||||
}
|
||||
}
|
||||
|
10
build.rs
10
build.rs
@ -11,6 +11,8 @@ use std::process::Stdio;
|
||||
use which::which;
|
||||
|
||||
fn main() {
|
||||
println!("cargo:rerun-if-changed=.gn");
|
||||
println!("cargo:rerun-if-changed=BUILD.gn");
|
||||
println!("cargo:rerun-if-changed=src/binding.cc");
|
||||
|
||||
// These are all the environment variables that we check. This is
|
||||
@ -120,10 +122,6 @@ fn build_v8() {
|
||||
gn_args.push("use_custom_libcxx=false".to_string());
|
||||
}
|
||||
|
||||
if !is_debug() {
|
||||
gn_args.push("v8_enable_handle_zapping=false".to_string());
|
||||
}
|
||||
|
||||
// Fix GN's host_cpu detection when using x86_64 bins on Apple Silicon
|
||||
if cfg!(target_os = "macos") && cfg!(target_arch = "aarch64") {
|
||||
gn_args.push("host_cpu=\"arm64\"".to_string())
|
||||
@ -133,15 +131,12 @@ fn build_v8() {
|
||||
println!("clang_base_path {}", clang_base_path.display());
|
||||
gn_args.push(format!("clang_base_path={:?}", clang_base_path));
|
||||
gn_args.push("treat_warnings_as_errors=false".to_string());
|
||||
// we can't use chromiums clang plugins with a system clang
|
||||
gn_args.push("clang_use_chrome_plugins=false".to_string());
|
||||
} else {
|
||||
println!("using Chromiums clang");
|
||||
let clang_base_path = clang_download();
|
||||
gn_args.push(format!("clang_base_path={:?}", clang_base_path));
|
||||
|
||||
if cfg!(target_os = "android") && cfg!(target_arch = "aarch64") {
|
||||
gn_args.push("clang_use_chrome_plugins=false".to_string());
|
||||
gn_args.push("treat_warnings_as_errors=false".to_string());
|
||||
}
|
||||
}
|
||||
@ -178,7 +173,6 @@ fn build_v8() {
|
||||
};
|
||||
|
||||
if target_triple == "aarch64-linux-android" {
|
||||
gn_args.push("is_component_build=false".to_string());
|
||||
gn_args.push(r#"v8_target_cpu="arm64""#.to_string());
|
||||
gn_args.push(r#"target_os="android""#.to_string());
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user