fix(desktop): request Windows libc variant for cross packaging
This commit is contained in:
1 parent
d0810c63dd
commit
b29cf1ad11
2 files changed
+3
-2
No files matched your search
@@ -564,7 +564,7 @@ export function installGetWindowsNativeBinding(
|
||||
|
||||
const crossTarget = platform !== process.platform || arch !== process.arch
|
||||
const installerArgs = crossTarget
|
||||
? ['install', `--target_platform=${platform}`, `--target_arch=${arch}`, '--fallback-to-build=false']
|
||||
? ['install', `--target_platform=${platform}`, `--target_arch=${arch}`, ...(platform === 'win32' ? ['--target_libc=unknown'] : []), '--fallback-to-build=false']
|
||||
: ['install', '--fallback-to-build']
|
||||
const result = spawn(process.execPath, [installerPath, ...installerArgs], {
|
||||
cwd: srcRoot,
|
||||
|
||||
@@ -647,5 +647,6 @@ test('get-windows cross-target install requests the target prebuild without comp
|
||||
spawn: (command, args) => { calls.push(args); return { status: 0 } }
|
||||
})
|
||||
assert.deepEqual(calls[0], ['/fake/node-pre-gyp', 'install',
|
||||
`--target_platform=${platform}`, '--target_arch=x64', '--fallback-to-build=false'])
|
||||
`--target_platform=${platform}`, '--target_arch=x64',
|
||||
...(platform === 'win32' ? ['--target_libc=unknown'] : []), '--fallback-to-build=false'])
|
||||
})
|
||||
Reference in new issue
Block a user