diff --git a/.gn b/.gn index ce64e43d74..8688703491 100644 --- a/.gn +++ b/.gn @@ -30,6 +30,10 @@ default_args = { # for now. See http://clang.llvm.org/docs/ControlFlowIntegrity.html is_cfi = false + # Disabled due to CRT linking problems in Windows when using prebuilt V8. + # Works in other configurations. + is_component_build = false + symbol_level = 1 treat_warnings_as_errors = true rust_treat_warnings_as_errors = true diff --git a/libdeno/BUILD.gn b/libdeno/BUILD.gn index 5cd774eaa4..6523697180 100644 --- a/libdeno/BUILD.gn +++ b/libdeno/BUILD.gn @@ -54,7 +54,11 @@ v8_static_library("libdeno") { } else if (is_linux) { libs = [ "//prebuilt/linux64/libv8.a" ] } else if (is_win) { - libs = [ "//prebuilt/win/v8.lib" ] + if (is_debug) { + libs = [ "//prebuilt/win/v8_debug.lib" ] + } else { + libs = [ "//prebuilt/win/v8.lib" ] + } } else { assert(false, "We don't have prebuilt binaries for this platform yet.") } diff --git a/prebuilt/win/v8_debug.lib.sha1 b/prebuilt/win/v8_debug.lib.sha1 new file mode 100644 index 0000000000..ed962c241a --- /dev/null +++ b/prebuilt/win/v8_debug.lib.sha1 @@ -0,0 +1 @@ +e080ce76661b4d90f6e7879e58273d64344a9680 \ No newline at end of file diff --git a/tools/prebuilt.py b/tools/prebuilt.py index 7542d7aa6c..46763cc9f3 100644 --- a/tools/prebuilt.py +++ b/tools/prebuilt.py @@ -5,12 +5,16 @@ from third_party import tp, google_env def download_v8_prebuilt(): if sys.platform == 'win32': - sha1_file = "prebuilt/win/v8.lib.sha1" + download_prebuilt("prebuilt/win/v8.lib.sha1") + # TODO Ideally we wouldn't have to download both builds of V8. + download_prebuilt("prebuilt/win/v8_debug.lib.sha1") elif sys.platform.startswith('linux'): - sha1_file = "prebuilt/linux64/libv8.a.sha1" + download_prebuilt("prebuilt/linux64/libv8.a.sha1") elif sys.platform == 'darwin': - sha1_file = "prebuilt/mac/libv8.a.sha1" + download_prebuilt("prebuilt/mac/libv8.a.sha1") + +def download_prebuilt(sha1_file): run([ "python", tp('depot_tools/download_from_google_storage.py'),