[nodejs] Enable exceptions (#423)

* feat: enable exceptions

* fix: windows exception handling flag value
This commit is contained in:
Matthew Keil 2024-04-30 13:53:52 -04:00 committed by GitHub
parent 8ab57f44db
commit 164827e3a8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -14,12 +14,13 @@
],
"defines": [
"__BLST_PORTABLE__",
"NAPI_DISABLE_CPP_EXCEPTIONS"
"NAPI_CPP_EXCEPTIONS"
],
"conditions": [
["OS!='win'", {
"sources": ["deps/blst/build/assembly.S"],
"cflags_cc": [
"-fexceptions",
"-std=c++17",
"-fPIC"
]
@ -28,15 +29,18 @@
"sources": ["deps/blst/build/win64/*-x86_64.asm"],
"defines": [
"_CRT_SECURE_NO_WARNINGS",
"_HAS_EXCEPTIONS=1"
],
"msbuild_settings": {
"ClCompile": {
"ExceptionHandling": "Sync",
"AdditionalOptions": ["/std:c++17"]
}
}
}],
["OS=='mac'", {
"xcode_settings": {
"GCC_ENABLE_CPP_EXCEPTIONS": "YES",
"CLANG_CXX_LIBRARY": "libc++",
"MACOSX_DEPLOYMENT_TARGET": "13.0"
}