We have to rename ?FAIL to ?ABORT once we require at least R13B04 for
building rebar. Macros with different arity were not supported by the
compiler before 13B04.
If running e.g. rebar generate using an OTP development build,
rebar will complain that reltool has the version "", which is
less than the required "0.5.2". This is because rebar_reltool
simply checks the path returned by code:which(reltool), which
doesn't yield version information if used in a development build.
This patch substitutes a more robust method (load reltool and
fetch the info from application:loaded_applications()).
As it happens, this will not be enough to make things work,
but now Reltool will explain that it cannot generate a spec
from a system that is not installed, giving a better hint
as to what needs to be done.
This patch contains two additions to simplenode.runner:
1. Check if vm.args exists in CWD; if so, use it. This makes it
easier to start multiple concurrent nodes on a single machine
from one rebar-created release (starting each node from its
own directory, with its own copy of vm.args and e.g.
sys.config, log directory, database directory, etc.)
2. Add the targets start_boot <file> and console_boot <file>.
This is used to select a different boot script. The 'setup'
application (http://github.com/esl/setup) builds a special boot
script for installation (all apps loaded but not started,
making it possible to run install hooks with the full code path
in place).
For now, this is just a proof of concept; would make sense to add a lot
of things, such as quick access to invoking rebar itself (with approproate
code reloading), as well as an eunit-aware version so that tests could be
run interactively.
By default, executables in paths such as /bin and /usr/local/bin have
the mode saying they can be executed by all.
The current version of escriptize only sets u+x, which creates problems
when copied directly in repositories and requiring other programs to
interact with them.
This change makes rebar follow the standard of linuxes and unixes by
setting the permission flag to a+x, allowing users, the group and others
to execute it.