diff --git a/lib/configure.js b/lib/configure.js index bc39302979..f4820b514b 100644 --- a/lib/configure.js +++ b/lib/configure.js @@ -244,25 +244,29 @@ function configure (gyp, argv, callback) { argv.push('-I', config) }) - // for AIX we need to set up the path to the exp file - // which contains the symbols needed for linking. - // The file will either be in one of the following - // depending on whether it is an installed or - // development environment: - // - the include/node directory - // - the out/Release directory - // - the out/Debug directory - // - the root directory + // For AIX and z/OS we need to set up the path to the exports file + // which contains the symbols needed for linking. var node_exp_file = undefined if (process.platform === 'aix' || process.platform === 'os390') { var ext = process.platform === 'aix' ? 'exp' : 'x' var node_root_dir = findNodeDirectory() - var candidates = ['include/node/node', - 'out/Release/node', - 'out/Debug/node', - 'node'].map(function(file) { - return file + '.' + ext - }) + var candidates = undefined + if (process.platform === 'aix') { + candidates = ['include/node/node', + 'out/Release/node', + 'out/Debug/node', + 'node' + ].map(function(file) { + return file + '.' + ext + }) + } else { + candidates = ['out/Release/obj.target/libnode', + 'out/Debug/obj.target/libnode', + 'lib/libnode' + ].map(function(file) { + return file + '.' + ext + }) + } var logprefix = 'find exports file' node_exp_file = findAccessibleSync(logprefix, node_root_dir, candidates) if (node_exp_file !== undefined) {