Skip to content

Commit

Permalink
Disable LTO to avoid missing symbols in some envs
Browse files Browse the repository at this point in the history
LTO may not always work correctly, for whatever reason, resulting in
e.g.

> node_modules/argon2/build/Release/argon2.node: undefined symbol: argon2_ctx

Removing LTO seems to be fine, and resolves the above issue.
  • Loading branch information
amarshall committed Aug 25, 2024
1 parent bd59748 commit 8f00613
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion binding.gyp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"Release": {
"target_conditions": [
["OS != 'win'", {
"cflags+": ["-fdata-sections", "-ffunction-sections", "-flto", "-fvisibility=hidden"],
"cflags+": ["-fdata-sections", "-ffunction-sections", "-fvisibility=hidden"],
"ldflags+": ["-Wl,--gc-sections"]
}]
],
Expand Down

0 comments on commit 8f00613

Please sign in to comment.