--- cargo-crates/v8-0.40.2/v8/BUILD.gn.orig 2021-01-19 00:12:40 UTC +++ cargo-crates/v8-0.40.2/v8/BUILD.gn @@ -4209,7 +4209,7 @@ v8_component("v8_libbase") { } } - if (is_linux || is_chromeos) { + if ((is_linux || is_chromeos) && !is_bsd) { sources += [ "src/base/debug/stack_trace_posix.cc", "src/base/platform/platform-linux.cc", @@ -4219,6 +4219,12 @@ v8_component("v8_libbase") { "dl", "rt", ] + } else if (is_bsd) { + sources += [ + "src/base/debug/stack_trace_posix.cc", + "src/base/platform/platform-freebsd.cc", + ] + libs = [ "rt", "execinfo" ] } else if (current_os == "aix") { sources += [ "src/base/debug/stack_trace_posix.cc", @@ -4698,6 +4704,7 @@ if (current_toolchain == v8_snapshot_toolchain) { "src/snapshot/mksnapshot.cc", "src/snapshot/snapshot-empty.cc", ] + libs = ["execinfo"] if (v8_control_flow_integrity) { sources += [ "src/deoptimizer/deoptimizer-cfi-empty.cc" ]