Seems like sed 4.1.5 on RHEL 5.3 doesn't support `-E`, and sed on OS X doesn't
support `-r` to activate the extended regexp mode. Best to avoid extended regexp
altogether for compatibility.
Fixes#495
If there already exists a valid tarball in the build location, e.g. as
artefact of a previous install using `--keep`, don't re-download the
file, as there is no need.
References #487
Previously, curl and wget were instructed to try to resume the download
if the destination file already exists. This is supposed to be done via
the "Range" HTTP header, but doesn't work well with CloudFront:
HTTP server doesn't seem to support byte ranges. Cannot resume.
CloudFront is supposed to support ranges, so I don't know what's going
on here. It might be failing only in case the existing file is a fully
downloaded tarball?
In any case, this disables resuming downloads and resorts to simply
re-downloading the tarball always, overwriting the existing file.
Fixes#487
Better to use -f than -e to check for a user-specified definition file.
With -e, if the user accidentally types the name of a directory (or, far
less likely, a device file) with the same name as the Ruby they're
trying to install, they end up with ruby-build doing absolutely nothing
at best, or an error message that could be pretty confusing at worst.
JRuby 9000 (the next major release) includes a backend that supports a
new JVM JIT compiler called Graal. Graal is based on OpenJDK but hasn't
been released yet.
http://openjdk.java.net/projects/graal/
Allows for passing environment variables specifically to the "make install"
step of package building.
This can be helpful for providing a different DESTDIR= to a ruby install from
the --prefix that is used
There doesn't seem to be a way to construct a sed invocation for
in-place editing that is compatible with both BSD and GNU sed.
http://stackoverflow.com/q/5694228/11687Fixes#475
The default shebang for binstubs in a JRuby installation is
`#!/usr/bin/env jruby`. On a rbenv-managed JRuby, this will execute the
`jruby` rbenv shim. In a situation where a JRuby tool like `gem` is
executed from within a running rbenv by a rbenv plugin, (e.g.
rbenv-gemset) this can trigger another rbenv run to resolve the shim.
This can lead to endless recursion of rbenv calls.
Fixes#471, closes#473
References jf/rbenv-gemset#56
I thought this was not necessary, but a number of people had problems
when linking to OS X's "readline" (actually Editline wrapper):
- Some components of Pry wouldn't work
- Writing literal Unicode characters was not possible #379
- The compilation would downright fail in some cases #82#461Fixes#461
If `-p|--patch` flag was set while invoking `ruby-build` or
`rbenv install`, ruby-build will use `patch -p0 -i -` to apply a patch
from stdin to Ruby, Rubinius, or JRuby source code before running the
rest of `build_package_*` commands.
References #443
We symlink Rubinius' `PREFIX/gems/bin` into `PREFIX/bin` so that new
RubyGems binstubs get added to the main bin directory and therefore
become available to rbenv.
However, by throwing away `irb`, `rake`, `rdoc`, and `ri` binstubs
during this process (which are non-executable and have an invalid
shebang), we break the same commands in latest versions of Rubinius.
This change ensures that these binstubs get preserved, their shebang
corrected to `#!PREFIX/bin/rbx`, their executable bit flipped on, and
copied over to the main bin directory.
Fixes#468
`grep -c` would correctly output "0", which is handled specially later
on, but would also exit with a nonzero status which would abort the
script. Piping the output to `wc` to do the counting makes the exit
status of grep irrelevant.
Fixes#447
Installing Rubinius would print "BUILD FAILED" at the `bundle` step but
the installation would proceed nevertheless and finish successfully.
It turns out that the `command ...` expression will trigger the ERR trap
on failure even when it's a part of `||` list or a condition inside an
`if` statement. This defies how the ERR trap is supposed to work, so the
workaround is to execute it in a subshell which doesn't inherit the ERR
trap of its parent.