diff --git a/src/index.ts b/src/index.ts index 64932f5..9e6b4c6 100644 --- a/src/index.ts +++ b/src/index.ts @@ -26,7 +26,7 @@ export async function createWindowsInstaller(options: Options): Promise { let useMono = false; const monoExe = 'mono'; - const wineExe = process.arch === 'x64' ? 'wine64' : 'wine'; + const wineExe = process.arch.endsWith('64') ? 'wine64' : 'wine'; if (process.platform !== 'win32') { useMono = true; @@ -56,6 +56,14 @@ export async function createWindowsInstaller(options: Options): Promise { if (useMono) { args.unshift(cmd); cmd = wineExe; + + if (process.arch.endsWith('64')) { + const x64EditPath = path.join(vendorPath, 'rcedit-x64.exe'); + const rcEditPath = path.join(vendorPath, 'rcedit.exe'); + + await fs.remove(rcEditPath); + await fs.copy(x64EditPath, rcEditPath); + } } await spawn(cmd, args); diff --git a/vendor/rcedit-x64.exe b/vendor/rcedit-x64.exe new file mode 100755 index 0000000..1f4e093 Binary files /dev/null and b/vendor/rcedit-x64.exe differ