2023-05-08 16:48:33 +00:00
|
|
|
diff --git a/node_modules/node-gyp-build/node-gyp-build.js b/node_modules/node-gyp-build/node-gyp-build.js
|
|
|
|
index 61b398e..3cc3be8 100644
|
|
|
|
--- a/node_modules/node-gyp-build/node-gyp-build.js
|
|
|
|
+++ b/node_modules/node-gyp-build/node-gyp-build.js
|
|
|
|
@@ -30,6 +30,9 @@ load.resolve = load.path = function (dir) {
|
2020-07-13 17:03:37 +00:00
|
|
|
if (process.env[name + '_PREBUILD']) dir = process.env[name + '_PREBUILD']
|
|
|
|
} catch (err) {}
|
|
|
|
|
|
|
|
+ // pkg fix: native node modules are located externally to the pkg executable
|
|
|
|
+ dir = dir.replace(/^\/snapshot\/.+?\/node_modules\//, path.dirname(process.execPath) + path.sep)
|
|
|
|
+
|
|
|
|
if (!prebuildsOnly) {
|
|
|
|
var release = getFirst(path.join(dir, 'build/Release'), matchBuild)
|
|
|
|
if (release) return release
|