Skip to content

Commit

Permalink
build: use C++11 ABI with libstdc++
Browse files Browse the repository at this point in the history
This macro needs to match between Node.js and addons that use C++
standard library types whose ABI differs (e.g. `std::string`).
Therefore, a value for this should be specified in `common.gypi`.
(Currently, the 32-bit ARM builds use this ABI, and other
platforms don’t. It might also be possible to set this value to `0`
instead, it’s only important that *a* value is specified.)

Refs: https://gcc.gnu.org/onlinedocs/libstdc++/manual/using_dual_abi.html
  • Loading branch information
addaleax committed Dec 26, 2020
1 parent d90fa19 commit d501773
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions common.gypi
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,7 @@
'defines': [
'V8_DEPRECATION_WARNINGS',
'V8_IMMINENT_DEPRECATION_WARNINGS',
'_GLIBCXX_USE_CXX11_ABI=1',
],

# Forcibly disable -Werror. We support a wide range of compilers, it's
Expand Down

0 comments on commit d501773

Please sign in to comment.