This target compiles node with "/" as the prefix and installs into a directory
like: "node-v0.8.6-darwin-x86_64". Then it creates a gzipped-tarball of that
directory, called something like: "node-v0.8.6-darwin-x86_64.tar.gz".
This "portable" mode rewrites the npm shebang to use the "node" executable
in the same directory relative to the "npm" script. This makes the "npm"
script "just work" even when "node" is not in the user's $PATH.
This mode is necessary for the precompiled binary packages that may potentially
be extracted to anywhere. The regular shebang-rewriting logic would normally
set the npm script's shebang to "/bin/node" which will not be present on anyone's
machine. In the end, we want the precompiled packages to be as user-friendly as
possible.
Previously, a command with a short stdio array would result in the child's
stdout and stderr objects set to null. For example:
var c = child_process.spawn(cmd, args, {stdio: ['pipe']});
// results in c.stdout === null.
The expected behavior is the above line functioning the same as this one:
var c = child_process.spawn(cmd, args, {stdio: ['pipe', null, null]});
// provides correct (non-null) c.stdout; as does the above, after this fix.
The installer does what amounts to `cp -p`. If the node binary is in use at
the time of the copy, it'd fail with a ETXTBSY error. That's why it's unlinked
first now.
* honor the --without-waf and --without-npm configure switches
* a small logic bug made the installer script install to $PWD instead of
/usr/local if --prefix= was not passed to configure
This fixes the problem that calling pause() on a socket would not
actually prevent 'data' events from being emitted. It also replaces
the existing test by a more elaborate one.
Ref: #3118
* node: tag Encode and friends NODE_EXTERN (Ben Noordhuis)
* fs: fix ReadStream / WriteStream missing callback (Gil Pedersen)
* fs: fix readFileSync("/proc/cpuinfo") regression (Ben Noordhuis)
* installer: don't assume bash is installed (Ben Noordhuis)
* Report errors properly from --eval and stdin (isaacs)
* assert: fix throws() throws an error without message property (koichik)
* cluster: fix libuv assert in net.listen() (Ben Noordhuis)
* build: always link sunos builds with libumem (Trent Mick)
* build: improve armv7 / hard-float detection (Adam Malcontenti-Wilson)
* https: Use host header as effective servername (isaacs)
* sunos: work around OS bug to prevent fs.watch() from spinning (Bryan Cantrill)
* linux: fix 'two watchers, one path' segfault (Ben Noordhuis)
* windows: fix memory leaks in many fs functions (Bert Belder)
* windows: don't allow directories to be opened for writing/appending (Bert Belder)
* windows: make fork() work even when not all stdio handles are valid (Bert Belder)
* windows: make unlink() not remove mount points, and improve performance (Bert Belder)
* build: Sign pkg installer for OS X (isaacs)
The old installer was a JS script, which didn't work if node had been
cross-compiled for another architecture. Replace it with a python script.
Fixes #3807.