nexe: vcbuild.bat nosign release x64 exited with code: 1
What happened: I’m trying to build a version of my node js project, but always get this error:
nexe 3.3.7
√ Downloading Node.jssource from: https://nodejs.org/dist/v12.16.3/node-v12.16.3.tar.gz
√ Already downloaded...
√ Compiling result
√ Configuring node build...
Compiling Node with arguments: nosign,release,x64
Note: vcbuild no longer signs by default. "nosign" is redundant.
Looking for Python
Python 2 found in C:\Python27\\python.exe
Looking for NASM
Looking for Visual Studio 2017
Failed to find a suitable Visual Studio installation.
Try to run in a "Developer Command Prompt" or consult
https://github.com/nodejs/node/blob/master/BUILDING.md#windows-1
√ Compiling Node with arguments: nosign,release,x64
√ Finished in 8.422s
(node:5552) UnhandledPromiseRejectionWarning: Error: vcbuild.bat nosign release x64 exited with code: 1
at new NexeError (C:\Users\dpapi\Documents\bot raffle\black rabbit\node_modules\nexe\lib\compiler.js:83:28)
at ChildProcess.<anonymous> (C:\Users\dpapi\Documents\bot raffle\black rabbit\node_modules\nexe\lib\compiler.js:274:28)
at Object.onceWrapper (events.js:417:26)
at ChildProcess.emit (events.js:310:20)
at maybeClose (internal/child_process.js:1021:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:286:5)
(node:5552) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 2)
(node:5552) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
What you expected to happen: Build the application
How to reproduce it (as minimally and precisely as possible): Create a file and enter this code:
const { compile } = require('nexe')
compile({
input: './index.js',
build: true, //required to use patches
ico: './favicon.ico',
verbose: true
}).then(() => {
console.log('success')
})
Environment:
- Platform(OS/Version):
- Host Node Version: 12.16.3
- Target Node Version: 12.16.3
- Nexe version: 3.3.7
- Python Version: 3.8.5
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Reactions: 4
- Comments: 33 (3 by maintainers)
I have run the command
nexe index.js -o test -t windows --buildagain with parameter--verbose. The output shows, that NASM is required and not installed. After installing NASM manually from here it works like a charm!You will need to install NASM manually here, after installing it, it worked without any errors!
nexe test.js --build --verbose -t windowsRequired to read ReadME. I solved this problem on Windows with help of the following steps:
The first building will be running for about 20 minutes, but others will be momently.
I solved it used this command:
npm i windows-build-tools -gto install all I needFor me, I was using node 10.16.0 LTS and nexe was working fine. Then I updated to node 14.x and things stopped working. I tried to build node myself but couldn’t get it to work. What worked for me is to just modify my build command to build with the previous LTS version of node I was using (and this one is available as a pre-build - https://github.com/nexe/nexe/releases/download/v3.3.3/windows-x64-10.16.0):
(I realize this means I don’t get the latest-n-greatest node features but my app doesn’t need/use them)
NASM is added to path ? @ridai260
But I think it would need Visual Studio too 😢 right?
Guys, @lamihax , @RuhmGlory @ElvisRetiz you need to install build dependencies of Node.js manually because you do build it locally. Consult https://github.com/nodejs/node/blob/master/BUILDING.md#windows or a BUILDING.mb per specific node.js version that you are targeting.