Skip to content

Problems with Electron compilation #11

@fedyfausto

Description

@fedyfausto

As the object, i downloaded the module via github and i place the folder into the node_modules and renamed it in noble-winrt so i tried to compile all with:
npm rebuild --runtime=electron --target=3.0.8 --arch=x64 --rebuild --disturl=https://atom.io/download/electron --build_from_source=true

and then i get these errors:

> noble-winrt@0.0.1 install D:\Progetti\Domo\ui\node_modules\noble-winrt
> node-pre-gyp install --fallback-to-build

node-pre-gyp WARN Using request for node-pre-gyp https download
module.js:549
    throw err;
    ^

Error: Cannot find module 'napi-thread-safe-callback'
    at Function.Module._resolveFilename (module.js:547:15)
    at Function.Module._load (module.js:474:25)
    at Module.require (module.js:596:17)
    at require (internal/module.js:11:18)
    at [eval]:1:1
    at ContextifyScript.Script.runInThisContext (vm.js:50:33)
    at Object.runInThisContext (vm.js:139:38)
    at Object.<anonymous> ([eval]-wrapper:6:22)
    at Module._compile (module.js:652:30)
    at evalScript (bootstrap_node.js:466:27)
gyp: Call to 'node -p "require('napi-thread-safe-callback').include"' returned exit status 1 while in binding.gyp. while trying to load binding.gyp
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack     at ChildProcess.onCpExit (C:\Users\fedyf\AppData\Roaming\nvm\v8.11.2\node_modules\npm\node_modules\node-gyp\lib\configure.js:336:16)
gyp ERR! stack     at emitTwo (events.js:126:13)
gyp ERR! stack     at ChildProcess.emit (events.js:214:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:198:12)
gyp ERR! System Windows_NT 10.0.17134
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\fedyf\\AppData\\Roaming\\nvm\\v8.11.2\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "configure" "--fallback-to-build" "--module=D:\\Progetti\\Domo\\ui\\node_modules\\noble-winrt\\native\\noble_winrt.node" "--module_name=noble_winrt" "--module_path=D:\\Progetti\\Domo\\ui\\node_modules\\noble-winrt\\native" "--napi_version=3" "--node_abi_napi=napi" "--napi_build_version=0" "--node_napi_label=electron-v3.0" "--python=C:\\Python27\\python.exe"
gyp ERR! cwd D:\Progetti\Domo\ui\node_modules\noble-winrt
gyp ERR! node -v v8.11.2
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute 'C:\Program Files\nodejs\node.exe C:\Users\fedyf\AppData\Roaming\nvm\v8.11.2\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js configure --fallback-to-build --module=D:\Progetti\Domo\ui\node_modules\noble-winrt\native\noble_winrt.node --module_name=noble_winrt --module_path=D:\Progetti\Domo\ui\node_modules\noble-winrt\native --napi_version=3 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=electron-v3.0 --python=C:\Python27\python.exe' (1)
node-pre-gyp ERR! stack     at ChildProcess.<anonymous> (D:\Progetti\Domo\ui\node_modules\node-pre-gyp\lib\util\compile.js:83:29)
node-pre-gyp ERR! stack     at emitTwo (events.js:126:13)
node-pre-gyp ERR! stack     at ChildProcess.emit (events.js:214:7)
node-pre-gyp ERR! stack     at maybeClose (internal/child_process.js:925:16)
node-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
node-pre-gyp ERR! System Windows_NT 10.0.17134
node-pre-gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "D:\\Progetti\\Domo\\ui\\node_modules\\node-pre-gyp\\bin\\node-pre-gyp" "install" "--fallback-to-build"
node-pre-gyp ERR! cwd D:\Progetti\Domo\ui\node_modules\noble-winrt
node-pre-gyp ERR! node -v v8.11.2
node-pre-gyp ERR! node-pre-gyp -v v0.11.0
node-pre-gyp ERR! not ok
Failed to execute 'C:\Program Files\nodejs\node.exe C:\Users\fedyf\AppData\Roaming\nvm\v8.11.2\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js configure --fallback-to-build --module=D:\Progetti\Domo\ui\node_modules\noble-winrt\native\noble_winrt.node --module_name=noble_winrt --module_path=D:\Progetti\Domo\ui\node_modules\noble-winrt\native --napi_version=3 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=electron-v3.0 --python=C:\Python27\python.exe' (1)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! noble-winrt@0.0.1 install: `node-pre-gyp install --fallback-to-build`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the noble-winrt@0.0.1 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

UPDATE

i run the npm install command into the module folder and the i run the rebuild command from root of my project and then i get A LOT of errors such as:
c:\program files (x86)\windows kits\10\include\10.0.17763.0\cppwinrt\winrt\windows.devices.enumeration.h(2484): error C2913

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions