Skip to content

Commit

Permalink
build: enable runtime linking
Browse files Browse the repository at this point in the history
Enable runtime linking of shared objects. This will
allow loading of symbols using the RTLD_GLOBAL flag.

PR-URL: nodejs/node#15286
Fixes: nodejs/node#15243
Reviewed-By: Gibson Fahnestock <[email protected]>
Reviewed-By: Gireesh Punathil <[email protected]>
Reviewed-By: Michael Dawson <[email protected]>
Reviewed-By: James M Snell <[email protected]>
  • Loading branch information
jBarz authored and Stephen Belanger committed Sep 21, 2017
1 parent ad0ae65 commit 05a6ec2
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 7 deletions.
2 changes: 1 addition & 1 deletion node.gyp
Original file line number Diff line number Diff line change
Expand Up @@ -784,7 +784,7 @@
'common.gypi',
],

'ldflags': ['-Wl,-bE:<(PRODUCT_DIR)/node.exp'],
'ldflags': ['-Wl,-bE:<(PRODUCT_DIR)/node.exp', '-Wl,-brtl'],
},
{
'target_name': 'node_exp',
Expand Down
5 changes: 2 additions & 3 deletions test/addons/dlopen-ping-pong/binding.gyp
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,9 @@
'xcode_settings': {
'OTHER_LDFLAGS': [ '-Wl,-undefined', '-Wl,dynamic_lookup' ]
}}],
# Pass erok flag to the linker, to prevent unresolved symbols
# from failing. Still, the test won't pass, so we'll skip it on AIX.
# Enable the shared object to be linked by runtime linker
['OS=="aix"', {
'ldflags': [ '-Wl,-berok' ]
'ldflags': [ '-Wl,-G' ]
}]],
},
{
Expand Down
3 changes: 0 additions & 3 deletions test/addons/dlopen-ping-pong/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@ const common = require('../../common');
if (common.isWindows)
common.skip('dlopen global symbol loading is not supported on this os.');

if (common.isAIX)
common.skip('this test does not pass on AIX.');

const assert = require('assert');
const path = require('path');
const os = require('os');
Expand Down

0 comments on commit 05a6ec2

Please sign in to comment.