Uncaught Error: %1 is not a valid Win32 application
AlanDan opened this issue · 1 comments
Hi,
I'm trying to use opencv4nodejs with vue on MacOS.
It seems to build everything correctly on MacOS.
Here is the problem:
1, I build a win32 version on MacOS
2, copy the package on a pc and run the xx.exe
3, I got an error, here is the detail:
Uncaught Error: %1 is not a valid Win32 application.
\?\C:\Users\Alexander Dai\AppData\Local\Temp\36a84a7b-b244-4032-9973-81ad2058494e.tmp.node
at process.module.(anonymous function) [as dlopen] (ELECTRON_ASAR.js:172:20)
at Object.Module._extensions..node (module.js:598:18)
at Object.module.(anonymous function) [as .node] (ELECTRON_ASAR.js:186:18)
at Module.load (module.js:503:32)
at tryModuleLoad (module.js:466:12)
at Function.Module._load (module.js:458:3)
at Module.require (module.js:513:17)
at require (internal/module.js:11:18)
at Object. (C:\Users\Alexander Dai\workshop\YPEditor-win32-x64\resources\app.asar\node_modules\opencv4nodejs\lib\cv.js:17:8)
at Object. (C:\Users\Alexander Dai\workshop\YPEditor-win32-x64\resources\app.asar\node_modules\opencv4nodejs\lib\cv.js:28:3)
I kind of know that I need to build a opencv4nodejs on a pc.
Would you mind to give me some suggestions or solutions thus I can build both 'mas' and 'win32' on my MacOS and run both well.
PS: My english is not good, sorry for that.
Thanks.
I had similar issue, and it seems that only solution is to build windows executable on windows - either VM or native.
see this comment for more:
electron/electron#1075 (comment)