Skip to content

Commit eab7165

Browse files
committed
macos build
1 parent 67f50e1 commit eab7165

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

binding.gyp

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
{
66
"variables": {
77
"arch%": "<!(uname -m)",
8-
"cflags_cpp": "gnu++20",
8+
"cflags_cpp": "-std=gnu++20 -fexceptions",
99
}
1010
},
1111
'OS=="linux"',
@@ -56,7 +56,7 @@
5656
["make_flags", "-j2"]
5757
],
5858
"defines": [
59-
"NAPI_DISABLE_CPP_EXCEPTIONS",
59+
# "NAPI_DISABLE_CPP_EXCEPTIONS",
6060
# Uncomment the next line to use Node-API instead of NAN
6161
# "CONNECTION_USE_NODE_API",
6262
"BOUNDDATUM_USE_NODE_API",
@@ -227,9 +227,12 @@
227227
#'-lodbc'
228228
],
229229
},
230-
"defines": ["LINUX_BUILD", "UNICODE"],
230+
"defines": ["LINUX_BUILD", "UNICODE", "NAPI_CPP_EXCEPTIONS"],
231231
"xcode_settings": {
232-
"CLANG_CXX_LANGUAGE_STANDARD": "<(cflags_cpp)"
232+
"CLANG_CXX_LANGUAGE_STANDARD": "<(cflags_cpp)",
233+
"GCC_ENABLE_CPP_EXCEPTIONS": "YES",
234+
"GCC_ENABLE_CPP_RTTI": "YES",
235+
"OTHER_CPLUSPLUSFLAGS": ["-fexceptions"]
233236
},
234237
"include_dirs": [
235238
"<!@(node -p \"'<(msodbc_include_folders)'.split(' ').join(' ')\")",

0 commit comments

Comments
 (0)