Commit graph

1673 commits

Author SHA1 Message Date
Brian H. Ward
f19c7d0785 Add 'cover_export_json' option 2015-03-11 06:09:07 -04:00
Fred Hebert
02de46d01f Merge pull request #463 from tuncer/profiler-msg
Print more info when profiling
2015-03-08 20:00:59 -04:00
Tuncer Ayaz
e8fe6c33ad Print more info when profiling
* profiler= is preliminary and will be replaced with a
  different interface
* fail gracefully if unknown profiler is passed
2015-03-08 18:48:59 +01:00
Fred Hebert
223d762f0d Merge pull request #461 from lrascao/fix/crash_empty_appup
Fix OTP .appup.src processing on empty lists
2015-03-02 10:22:00 -05:00
Luis Rascao
2ebd804e1e Fix OTP .appup.src processing on empty lists
Expand test cases to handle .appup.src with
empty upgrade from and downgrade to lists, lift
larger .appup.src file from OTP's
lib/dialyzer/test/r9c_SUITE_data/src/asn1/asn1.appup.src
2015-03-02 11:47:36 +00:00
Tristan Sloughter
e7933d83b9 Merge pull request #459 from cmeiklejohn/emu-64
Remove -m64 flag.
2015-02-26 12:03:03 -06:00
Christopher Meiklejohn
3bc43753e5 Remove -m64 flag.
On 64-bit Linux, remove the emulation mode flag, given -m64 is an
invalid emulation mode on 64-bit Linux.

Example compilation from Basho's erlang_js on Linux:

```
ld: unrecognised emulation mode: 64
Supported emulations: elf_x86_64 elf32_x86_64 elf_i386 i386linux elf_l1om elf_k1om i386pep i386pe
make[4]: *** [Linux_All_OPT.OBJ/libjs.so] Error 1
```
2015-02-26 12:34:29 -05:00
Fred Hebert
d4675a5b06 Merge pull request #458 from manderson26/ma/improve_variable_expansion
Change env var delimiter to match non-word
2015-02-25 14:22:26 -05:00
Mark Anderson
e211afdce6 Change env var delimiter to match non-word
If I pass an expression like: "$PWD/deps/local/lib" in the port env
string, it expands to "/deps/local/lib", (variable is expanded to the
empty string) but if I pass "${PWD}/deps/local/lib" it expands
properly. I found that confusing.

This was because we require environment vars to end with whitespace,
while I think requiring a non-word character would be sufficient, since
the variables can only contain word characters.

This changes the expansion system to recognize variables that are
terminated by non word characters.

This includes some fixes as per some comments by tuncer.

Fixes rebar/rebar#457
2015-02-23 19:11:51 -08:00
Fred Hebert
f56268383a Merge pull request #452 from yannayl/patch-1
added 'shell' command to bash-completion
2015-02-15 11:23:31 -05:00
yannayl
da7d413fb0 Add 'shell' sub-command to shell-completion 2015-02-13 09:05:33 +00:00
Fred Hebert
7f73b8d365 Merge pull request #449 from lrascao/feature/support_appup_src_files
Support .appup.src files
2015-02-05 08:12:43 -05:00
Luis Rascao
53fbb7cf8e Support .appup.src[.script] files
Similar to how .app.src are being handled, all files in directory
.src ending with .appup.src are processed, checked for
correctness and copied to ebin without the .src extension.

By way of using rebar_config:consult_file/1, .appup.src.script
files are automatically supported in exactly the same manner
as in .app.src.script.
2015-02-04 22:33:16 +00:00
Fred Hebert
0eecd4d050 Merge pull request #378 from irpab/remove_last_dot_in_deps_dir
deps: fix delete-deps if deps_dir ends with dot
2015-02-04 14:48:19 -05:00
Pavel Baturko
703a9dae9e deps: fix delete-deps if deps_dir ends with dot
Remove possible last dot from deps dir path by calling
dirname on base_dir, deps_dir and dummy path part.
With this fix delete-deps command deletes dependencies
properly in case of deps dir path ended with dot.
Examples of deps_dir config value that triggers error:
".", "some/path/.".
Code that triggers error: rebar_deps:'delete-deps'/2,
code line lists:prefix(DepsDir, D#dep.dir).
If deps_dir = ".", cwd = "/root", dependency name = "app"
then DepsDir = "/root/." and D#dep.dir = "/root/app" so
prefix fun returns false but should be true.
Dependency app will not be removed because of this.
2015-02-03 23:21:46 +03:00
Fred Hebert
c051530b3c Merge pull request #445 from norton/norton-erlc-order
rebar doesn't respect the order of erl_first_files given in the rebar.conf file
2015-02-02 11:06:12 -05:00
Fred Hebert
7811c1f335 Merge pull request #447 from lrascao/feature/support_custom_proto_dir
Support custom protobuf directory
2015-02-02 11:05:47 -05:00
Luis Rascao
bf2b3e2468 Support custom protobuf directory
proto_opts config option contains the compiler directive
that defines which proto compiler to use, also contains a
src_dirs entry that defines a list of locations for the
.proto files to be processed.

Add integration test that compiles .proto files from src
and from proto directory specified in separate rebar
config files
2015-01-31 19:47:59 +00:00
Fred Hebert
fffc745e11 Merge pull request #305 from liskin/linux-multiarch-64
Fix compiler invocation on multiarch Linux
2015-01-30 11:35:13 -05:00
Fred Hebert
48e041dd9e Merge pull request #444 from tuncer/app-warning
Fix incorrect "not an app dir" warning
2015-01-27 09:09:48 -05:00
Tuncer Ayaz
59d1d0c34d Fix incorrect "not an app dir" warning 2015-01-27 12:08:59 +01:00
Joseph Wayne Norton
27cd98ef1d Test order for erl_first_files 2015-01-26 20:41:38 -06:00
Slava Yurin
d7657ba732 Keep order for erl_first_files 2015-01-26 20:41:38 -06:00
Fred Hebert
b488179030 Merge pull request #424 from tomas-abrahamsson/gpb-recompilation-detection-2
Gpb recompilation detection (using base compiler)
2015-01-26 18:54:19 -05:00
Fred Hebert
930d2c7f34 Merge pull request #437 from vladdu/fix_app_src
Fix .app.src.script bug introduced in b44b4f4
2015-01-26 18:53:52 -05:00
Luis Rascao
9b1f807f0c gpb: add inttest for recompilation with no changes 2015-01-24 22:11:05 +01:00
Tomas Abrahamsson
1ce7059adb Recompile .proto files with gpb also with prefix/suffix
For protocol buffer files, when there were gpb options to alter the
module name with prefix or suffix, recompilation was not properly
detected. This is now fixed. (Issue #384).

Use the rebar_base_compiler's ability to specify both source and
target file names, to be able to also support prefixes.

This also introduces a call to gpb_compile:format_error, so the xref
recipe needs to be updated to ignore it, to avoid false errors.
2015-01-24 22:11:04 +01:00
Tomas Abrahamsson
2e9706fd61 Make the base compiler accept target file names
The rebar_base_compiler:run/5 is an alternative to run/8, where
instead of source/target dirs and file name extensions, it takes
a list of tuples: [{SourceFileName, TargetFileName}], after the
idea by Tuncer Ayaz in discussion with Luis Rascão and me.

This is useful for situations where the target file name cannot be
expressed as only a new suffix or extension.  For example the gpb
protocol buffer compiler can take an option to add a file name prefix
as well as a suffix.

As a result, the values passed around inside the internal functions in
rebar_base_compiler are either source file names (eg. when the run/4
function has been called), or items, which are two-tuples
{SourceFileName,TargetFileName} (when the run/7,8 or /5 functions have
been called).
2015-01-24 22:11:04 +01:00
Tomas Abrahamsson
135e629bc0 Use rebar_utils:find_files_by_ext/2,3 2015-01-24 22:11:04 +01:00
Tomas Abrahamsson
a04530124f Add rebar_utils:find_files_by_ext/2,3
This finds files by extension, avoiding resource fork files
in Mac OS X.
2015-01-24 22:11:04 +01:00
Fred Hebert
83156cc1ef Merge pull request #430 from robertoaloi/fail-if-nodetool-eval-fails
Exit with proper status code if 'eval' fails
2015-01-23 08:39:49 -05:00
Fred Hebert
6586c61e26 Merge pull request #442 from tuncer/travis-info
.travis.yml: print information before running script
2015-01-23 08:39:08 -05:00
Roberto Aloi
0d5416218b Exit with proper status code if 'eval' fails 2015-01-23 08:31:58 +01:00
Tuncer Ayaz
332bbf3de9 .travis.yml: print information before running script 2015-01-22 22:23:05 +01:00
Fred Hebert
78379493d4 Merge pull request #440 from tuncer/obsolete-file
Delete obsolete file
2015-01-22 10:46:02 -05:00
Tuncer Ayaz
b2eb09c565 Delete obsolete file 2015-01-21 15:24:14 +01:00
Fred Hebert
73be1ea47e Merge pull request #426 from seriyps/mv-upgrade-to-nodetool
Fixed #133. Release upgrade now handle long and short names properly.
2015-01-20 12:43:19 -05:00
Vlad Dumitrescu
5f0ab0268e Fix .app.src.script bug introduced in b44b4f4
Handle the case when both .app.src and .app.src.script exist;
the script takes precedence.
2015-01-20 17:09:11 +01:00
Сергей Прохоров
0a1961fb0d Fixed #133. Release upgrade handle long and short names properly.
Implemented, by moving upgrade functionality from install_upgrade.escript
to nodetool, which already supports both short and long names.
Make install_upgrade.escript as wrapper for nodetool for backward compatibility.
2015-01-20 10:18:10 +03:00
Fred Hebert
25aca7ed39 Merge pull request #433 from tuncer/ct3
inttest/ct3: fix overlong line
2015-01-14 18:14:57 -05:00
Tuncer Ayaz
7520ad62ba inttest/ct3: fix overlong line 2015-01-14 23:19:16 +01:00
Fred Hebert
890390b1c4 Merge pull request #421 from tuncer/fix-travis-ci-shortname
inttest/ct3: fix travis-ci breakage
2015-01-14 15:20:13 -05:00
Tuncer Ayaz
ebebeb0318 Fix travis-ci tests
Spinning up a distributed Erlang node by running 'erl -name ct3' failed
due to FQDN issues. Hiro Asari from Travis-CI suggested to try out the
new container-based workers as a fix, and that one works as expected
because we get a proper FQDN. Therefore, make the switch to
container-based workers.
2015-01-14 21:12:38 +01:00
Fred Hebert
107c9af2ed Merge pull request #432 from tuncer/doc
Document recursive_cmds in -r help string as well
2015-01-14 14:59:36 -05:00
Fred Hebert
22ff2ef771 Merge pull request #428 from tomas-abrahamsson/mock-gpb-and-protobuffs-in-inttest
Remove a git url in gpb and protobuffs inttest configs
2015-01-14 14:54:21 -05:00
Tuncer Ayaz
1d20be707f Document recursive_cmds in -r help string as well
{recursive_cmds, []} was already documented as part of the core
rebar.config options that gets printed via 'rebar -h', but this wasn't
sufficiently informative.  To fix this, explain the use of
recursive_cmds as part of the -r help string.

Reported-by: Stefan Strigler
2015-01-14 20:23:05 +01:00
Tomas Abrahamsson
5182ded01c Remove a git url in gpb and protobuffs inttest configs
In the rebar.config files for the gpb and protobuffs inttests, use the
{Name, Version} dependency form instead of {Name, Version, Source},
since the Source is not really applicable; the mocks are copied into
place by the proto_gpb_rt:files/0 and proto_protobuffs_rt:files/0.
Idea and suggestion by Tuncer Ayaz.
2015-01-13 00:11:47 +01:00
Fred Hebert
473d9fe145 Merge pull request #425 from tomas-abrahamsson/mock-gpb-and-protobuffs-in-inttest
Copy instead of rsync gpb and protobuffs inttest mocks
2015-01-12 09:18:21 -05:00
Tomas Abrahamsson
a8ffba6da5 Copy instead of rsync gpb and protobuffs inttest mocks
Installation of the gpb and protobuffs mocks, in inttest, is now done
using copy in proto_{gpb,protobuffs}_rt:files/0.  Previously, rebar
prepare-deps was used, the dependencies had an rsync source with a
relative path back to the inttest directory.  This eliminates a
dependency in inttest to rsync, instead relying on retest's
functionality to copy files and directories.  Also, it eliminates
hidden knowledge about the directory layout that retest chooses.
Idea and suggestion by Tuncer Ayaz.

Since the dependency sources in the inttest rebar.config files are no
longer used, they are now changed back from rsync paths to git urls,
to serve as examples.
2015-01-10 23:18:49 +01:00
Fred Hebert
3288afa5c1 Merge pull request #418 from tuncer/fix-415
Fix #415 (reltool vsn check)
2015-01-09 14:52:13 -05:00