build: enable runtime linking
Enable runtime linking of shared objects. This will allow loading of symbols using the RTLD_GLOBAL flag. PR-URL: https://github.com/nodejs/node/pull/15286 Fixes: https://github.com/nodejs/node/issues/15243 Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com> Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: James M Snell <jasnell@gmail.com>
This commit is contained in:
parent
3070d53e31
commit
c5eb5bfc2e
2
node.gyp
2
node.gyp
@ -784,7 +784,7 @@
|
|||||||
'common.gypi',
|
'common.gypi',
|
||||||
],
|
],
|
||||||
|
|
||||||
'ldflags': ['-Wl,-bE:<(PRODUCT_DIR)/node.exp'],
|
'ldflags': ['-Wl,-bE:<(PRODUCT_DIR)/node.exp', '-Wl,-brtl'],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
'target_name': 'node_exp',
|
'target_name': 'node_exp',
|
||||||
|
@ -10,10 +10,9 @@
|
|||||||
'xcode_settings': {
|
'xcode_settings': {
|
||||||
'OTHER_LDFLAGS': [ '-Wl,-undefined', '-Wl,dynamic_lookup' ]
|
'OTHER_LDFLAGS': [ '-Wl,-undefined', '-Wl,dynamic_lookup' ]
|
||||||
}}],
|
}}],
|
||||||
# Pass erok flag to the linker, to prevent unresolved symbols
|
# Enable the shared object to be linked by runtime linker
|
||||||
# from failing. Still, the test won't pass, so we'll skip it on AIX.
|
|
||||||
['OS=="aix"', {
|
['OS=="aix"', {
|
||||||
'ldflags': [ '-Wl,-berok' ]
|
'ldflags': [ '-Wl,-G' ]
|
||||||
}]],
|
}]],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -4,9 +4,6 @@ const common = require('../../common');
|
|||||||
if (common.isWindows)
|
if (common.isWindows)
|
||||||
common.skip('dlopen global symbol loading is not supported on this os.');
|
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 assert = require('assert');
|
||||||
const path = require('path');
|
const path = require('path');
|
||||||
const os = require('os');
|
const os = require('os');
|
||||||
|
Loading…
x
Reference in New Issue
Block a user