Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 541870

Summary: virtual ebuild for nodejs implementations/forks
Product: Gentoo Linux Reporter: Jiří Helebrant <helb>
Component: New packagesAssignee: Johan Bergström <bugs>
Status: RESOLVED WONTFIX    
Severity: normal CC: patrick, proxy-maint
Priority: Normal Keywords: EBUILD
Version: unspecified   
Hardware: All   
OS: All   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: virtual/nodejs ebuild

Description Jiří Helebrant 2015-03-02 08:57:14 UTC
Created attachment 397844 [details]
virtual/nodejs ebuild

Since IO.js is already in Portage tree, it would be useful to allow users to choose to actually use it in place of nodejs.

So we would need a new virtual ebuild with RDEPEND="|| ( net-libs/nodejs net-libs/iojs )" and change all dependencies on net-libs/nodejs to this virtual ebuild.

I am not sure about the versioning here, because "original" nodejs uses 0.1x.xx and iojs jumped up to 1.x.x instead. I guess we can take some inspiration from ffmpeg/libav, which each uses different version sequence as well.

Also, I don't know if everything written for node.js is compatible with IO.js. Everything I tried so far works without any problem, but some automated test would be useful.
Comment 1 Johan Bergström 2015-03-06 10:28:44 UTC
Sorry to say, but this is a bad idea for many reasons:
1. We mostly only do virtuals when other packages commonly depend on either. In the io.js/node case it's very rare.
2. Assuming that switching between io.js and nodejs is as easy as eselecting is poor ui. You need to rebuild all native modules. There are also other assumptions we can't make.

Most major (native) packages has updated to support io.js. io.js and nodejs will further diversify as nodejs chooses to stay with an out of date v8. This makes supporting switching from a packaging perspective very hard.

Feel free to ping me at irc if you have further thoughts: jbergstroem@freenode.