electron-builder: OS X: Error: Module version mismatch. Expected 48, got 49
- ^5.30.0:
- 1.3.3:
When trying to build for OS X getting the following error:
tsc && node-gyp rebuild && build --mac
Error: Module version mismatch. Expected 48, got 49. at Error (native) at Object.Module._extensions…node (module.js:583:18) at Module.load (module.js:473:32) at tryModuleLoad (module.js:432:12) at Function.Module._load (module.js:424:3) at Module.require (module.js:483:17) at require (internal/module.js:20:19) at Object.<anonymous> (/Users/Jenia/Desktop/git/electron-angular2-native/node_modules/macos-alias/lib/create.js:7:13) at Module._compile (module.js:556:32) at Object.Module._extensions…js (module.js:565:10) at Module.load (module.js:473:32) at tryModuleLoad (module.js:432:12) at Function.Module._load (module.js:424:3) at Module.require (module.js:483:17) at require (internal/module.js:20:19) at Object.<anonymous> (/Users/Jenia/Desktop/git/electron-angular2-native/node_modules/macos-alias/index.js:1:18) at Module._compile (module.js:556:32) at Object.Module._extensions…js (module.js:565:10) at Module.load (module.js:473:32) at tryModuleLoad (module.js:432:12) at Function.Module._load (module.js:424:3) at Module.require (module.js:483:17) at require (internal/module.js:20:19) at Object.<anonymous> (/Users/Jenia/Desktop/git/electron-angular2-native/node_modules/ds-store/index.js:2:13) at Module._compile (module.js:556:32) at Object.Module._extensions…js (module.js:565:10) at Module.load (module.js:473:32) at tryModuleLoad (module.js:432:12) From previous event: at tsAwaiter (/Users/Jenia/Desktop/git/electron-angular2-native/node_modules/electron-builder/src/util/awaiter.ts:10:47) at Object.build (/Users/Jenia/Desktop/git/electron-angular2-native/node_modules/electron-builder/src/builder.ts:195:52) at Object.<anonymous> (/Users/Jenia/Desktop/git/electron-angular2-native/node_modules/electron-builder/src/build-cli.ts:27:28) at Module._compile (module.js:556:32) at Object.Module._extensions…js (module.js:565:10) at Module.load (module.js:473:32) at tryModuleLoad (module.js:432:12) at Function.Module._load (module.js:424:3) at Module.runMain (module.js:590:10) at run (bootstrap_node.js:394:7) at startup (bootstrap_node.js:149:9) at bootstrap_node.js:509:3
To reproduce:
- Pull this repository: https://github.com/meltedspark/electron-angular2-native
- Run
npm install - Run
npm run dist:osx
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 21 (19 by maintainers)
Commits related to this issue
- feat: add node-gyp-rebuild #683 — committed to electron-userland/electron-builder by develar 8 years ago
- Fix OS X build problem (remove .npmrc), align to appropriate electron-builder version https://github.com/electron-userland/electron-builder/issues/683 — committed to just-jeb/electron-angular-native by deleted user 8 years ago
- docs: clarify native addons build process (#691) Add clarification regarding how native addons that are not dependencies but a part of the project should be treated https://github.com/electron-use... — committed to electron-userland/electron-builder by deleted user 8 years ago
node-gyp-rebuildbin will be added.Set
"nodeGypRebuild": truein yourbuildand remove.npmrcfile.Option
nodeGypRebuildwill be added in 10 minutes. You just set it to true and electron-builder will call it for you with proper env/conf.I’m not sure this is correct. I use the following in my root
binding.gypfor specifying which dependencies to compile:As you can see it skips all the
node_modulesfolders. Sincenode-gyp rebuildlooks for thebinding.gypin the directory it was called from, I can’t see hownode-gyp rebuildinvocation would build themacos-alias.Ok, I will investigate.