nw-builder icon indicating copy to clipboard operation
nw-builder copied to clipboard

Unable to build nw.js hello world application

Open mpsbhat opened this issue 10 years ago • 6 comments

Myself trying to build a hello world application for Linux using nw-builder. It runs when I execute the run command nwbuild -r /path/to/myapp but when i am trying to build it for linux version it gives the following error.

{ [Error: ENOENT, no such file or directory '/usr/local/lib/node_modules/nw-builder/cache/0.13.0-beta4/linux32/nw.pak'] errno: 34, code: 'ENOENT', path: '/usr/local/lib/node_modules/nw-builder/cache/0.13.0-beta4/linux32/nw.pak', syscall: 'lstat' }

When I checking the path for directory in cache folder, instead of nw.pk file i found nw_100_percent.pak and resources.pak files.

How can i solve the same? Also is it possible to avoid the downloading of nw.js each time when I run or build the application? I tried it with giving the version number but not succeeded.

mpsbhat avatar Jan 20 '16 05:01 mpsbhat

See https://github.com/tomlandia/nw-builder/commit/e70b98d5881d983104d6399b4f384cdfae8ccc15 Remove edit lib/platforms.js and remove nw.pak

ekigwana avatar Jan 20 '16 22:01 ekigwana

But I can't remove that files @ekigwana because each time when I am trying to build the application, it download fresh copy to cache folder immediately it throws the above mentioned error. Is there any way to avoid download?

mpsbhat avatar Jan 22 '16 04:01 mpsbhat

What I do is 1. npm install nw-builder 2. Patch nw-builder. 3. Run gulp. I use cmake or bash scripts. You can A. Download nw-builder and add its contents to a subdir in your project. Edit the file. Edit json dependency and instead of version info, repkace with "file:./modules/nw-builder" and it becomes part of your code.

ekigwana avatar Jan 22 '16 05:01 ekigwana

I have same issue with linux build, and windows build is missing ffmpegsumo.dll. Macos build works fine for x64 version. I'm using "nwbuild 0.13.0-beta5"

Posible workaround untill this is fixed could be to add -v 0.12.3 switch to build with previous stable version. After i added this, i succesfuly got windows exe built...

onedevteam avatar Feb 12 '16 15:02 onedevteam

They really need to update the builder to support the new version of NWJS

Sytten avatar Feb 25 '16 20:02 Sytten

@mpsbhat sorry about this. You need to specify a NW.js version in your options. #275 would fix this.

adam-lynch avatar Mar 11 '16 17:03 adam-lynch