I’m newbie to both Node and Electron.
I had two libraries,
"libqcocoa.dylib", then I created a
"addon.node" followed nodejs/nan. It works fine at my develop folder.
Situation a) But I got this
Error: dlopen(/Users/OuO/FirstApp-darwin-x64/FirstApp.app/Contents/Resources/app/build/Release/hello.node, 1): Library not loaded: libqcocoa.dylib. when I executed it as an app.
I guess that is something wrong with my binding.gyp path setting. Here is my develop folder:
When I command
"electron main.js" at folder
MyAppFolder, everything works correctly.
Situaion b) If I type
"electron MyAppFolder/main.js" at the parent folder of
MyAppFolder, I would have a similar error:
1): Library not loaded: libqcocoa.dylib.
It seems like the dylib links work incorrectly. I found that electron tried to load
"libqcocoa.dylib " from where I typed
electron. The situation b) can be fixed by adding these two library to the parent folder of
MyAppFolder. However, I have no idea how to fix the situation a).
Can any one help? Appreciated.