diff --git a/node.gyp b/node.gyp index ed20a490d9ee1d..43ba985df54111 100644 --- a/node.gyp +++ b/node.gyp @@ -956,6 +956,11 @@ ['OS=="solaris"', { 'ldflags': [ '-I<(SHARED_INTERMEDIATE_DIR)' ] }], + [ 'node_shared=="true"', { + 'xcode_settings': { + 'OTHER_LDFLAGS': [ '-Wl,-rpath,@loader_path', ], + }, + }], ], } ], # end targets