Atom-shell and Meteor


#1

Hello. I am trying to get an atom-shell working with Meteor. At this point, I am at the point where the app fails to load fibers. I don’t know what else I can do make it work. I’ve tried everything I can find on google. Basically the problem is this. npm install, or apm install, installs a variety of fibers binaries into node_modules/fibers/bin:
linux-ia32-v8-3.11
linux-ia32-v8-3.14
linux-ia32-v8-3.6
linux-x64-v8-3.11
linux-x64-v8-3.14
linux-x64-v8-3.6

But when I run atom-shell, the process.versions is this:
{ http_parser: ‘2.3’,
node: ‘1.0.0-pre’,
v8: ‘3.30.33.15’,
uv: ‘1.2.0’,
zlib: ‘1.2.8’,
modules: ‘41’,
openssl: ‘1.0.1j’,
‘atom-shell’: ‘0.21.3’,
chrome: ‘40.0.2214.91’ }

So it uses the v8 node, and tries to load node_modules/fibert/bin/linux-x64-v8-3.30/fibers.node, which of course doesn’t exist. Any ideas on how I can get around this issue?

Thank you,
David Logan


#2

I’m having a similar probem with node-sass when the node module is installed it correctly gets that my system is win32-x64-node-0.12 but when you look at process.sassBinaryName it is win32-ia32-atom-1.0 still not sure how I would go about fixing it.


Apm not installing correct node-sass binding
#3

So I’ve built v8, node, and nodewebkit about a thousand times over the last couple of weeks in an attempt to get all of this fixed. What seems to be happening is that the authors of the various packages don’t seem to be concerned about maintaining these dependencies (I am using nodewebkit and atom-shell interchangeably, since they are almost identical.)

Basically, node pulls in some version of Google’s v8 library (which is where the ‘v8’ version comes in.) Node itself also has a module version (‘modules’ in process.versions.) When you “npm install”, it uses the whatever version of node that’s installed on the machine (not the one compiled into nodewebkit), and whatever v8 was compiled into node.

When nodewebkit was built, it pulled in the sources for some other version of node, AND some other version of v8, and then compiles all of it itself. So the v8 compiled into nodewebkit doesn’t match the v8 compiled into node, and even the version of node compiled into nodewebkit doesn’t match the version of node installed on the machine! This is all true even if you install node, and then “npm install nodewebkit” or “npm install atom-shell.” You end up with a package in node_modules that has a completely different version of node and a completely different version of v8 than the node that was used to install it.

This all means that there is simply no hope of using any package where there is a binary module installed by npm, such as fibers.

I’ve spent the last couple of weeks trying to get a v8 built, then a node built with the v8, then a nodewebkit build with my v8 and my node. But then I run into hordes of compile problems, changed sources, removed sources, added sources, missing configuration lines, and the list goes on. None of these projects work together at all.

I’m not sure how the community is missing this, but I think it needs to be rectified. Instead of pulling in these sources into their own projects, they need to pull the dependent projects, either as .o or .so, and just use them as the dependent projects are released. That way everyone always uses at least some known, standard, tagged, version of dependencies like v8 and node.

Please somebody tell me that I am wrong, and that I am missing something fundamental. I have got to get my company’s project to a point where I can run my application natively on various desktops.

And if I’m right, and this really is a valid thing for the community to do, I sure would like to understand why, so that I can at least explain it to the people holding me accountable for making this work.

Thank you,
David Logan


#4

Hey @djlogan2!

I’ve been working on a boilerplate for Electron + Meteor. You can read about it here: https://sircharleswatson.github.io/2015/04/30/Electrometeor-Build-Desktop-Applications-With-Electron-Meteor.html

You can check out the source here: https://github.com/sircharleswatson/Electrometeor

I hope it works well for you!


#5

I think this is because electron uses iojs which uses a newer version of v8 than nodejs.

I got my electron/meteor app running on mac. darwin-x64-v8-4.1 was missing on the mac, which I found here:
https://github.com/Paxa/postbird/tree/master/node_modules/fibers/bin

Now I am trying to get it to work on win. win32-ia32-v8-4.2 is missing on win.


#6

I got it working with atom-shell v0.23.0 and using iojs v1.4.3 instead of nodejs and using this fix for fibers.