summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoralisdair sullivan <alisdairsullivan@yahoo.ca>2015-10-15 21:40:33 -0700
committeralisdair sullivan <alisdairsullivan@yahoo.ca>2015-10-26 21:57:32 -0700
commit621d8a94856df629a94fac7a77b68fd841267510 (patch)
treeb0acb804bd12853e67615f531a392639d9926652
parent4ad998b7187a5910304ffeef867571400b6b4c61 (diff)
Revert "add an export to allow specifing arbitrary extra erl files to be compiled"
This reverts commit 9d82215296205d2d30c152c7d7c6fcb8e4a92443.
-rw-r--r--src/rebar_erlc_compiler.erl7
-rw-r--r--test/rebar_compile_SUITE.erl31
2 files changed, 1 insertions, 37 deletions
diff --git a/src/rebar_erlc_compiler.erl b/src/rebar_erlc_compiler.erl
index b9192c3..06d09bd 100644
--- a/src/rebar_erlc_compiler.erl
+++ b/src/rebar_erlc_compiler.erl
@@ -28,7 +28,6 @@
-export([compile/1,
compile/3,
- compile/4,
clean/1]).
-include("rebar.hrl").
@@ -105,11 +104,6 @@ compile(Opts, Dir, OutDir) ->
fun compile_mib/3),
doterl_compile(Opts, Dir, OutDir).
--spec compile(rebar_dict(), file:filename(), file:filename(), [file:filename()]) -> 'ok'.
-compile(Opts, Dir, OutDir, More) ->
- ErlOpts = rebar_opts:erl_opts(Opts),
- doterl_compile(Opts, Dir, OutDir, More, ErlOpts).
-
-spec clean(file:filename()) -> 'ok'.
clean(AppDir) ->
MibFiles = rebar_utils:find_files(filename:join(AppDir, "mibs"), ?RE_PREFIX".*\\.mib\$"),
@@ -494,7 +488,6 @@ needs_compile(Source, Target) ->
filelib:last_modified(Source) > filelib:last_modified(Target).
gather_src([], Srcs) ->
- ?DEBUG("src_files ~p", [Srcs]),
Srcs;
gather_src([Dir|Rest], Srcs) ->
gather_src(
diff --git a/test/rebar_compile_SUITE.erl b/test/rebar_compile_SUITE.erl
index 561e657..cc37441 100644
--- a/test/rebar_compile_SUITE.erl
+++ b/test/rebar_compile_SUITE.erl
@@ -26,8 +26,7 @@
only_default_transitive_deps/1,
clean_all/1,
override_deps/1,
- profile_override_deps/1,
- build_more_sources/1]).
+ profile_override_deps/1]).
-include_lib("common_test/include/ct.hrl").
-include_lib("eunit/include/eunit.hrl").
@@ -681,31 +680,3 @@ profile_override_deps(Config) ->
Config, RebarConfig, ["as", "a", "compile"],
{ok, [{dep, "some_dep"},{dep_not_exist, "other_dep"}]}
).
-
-build_more_sources(Config) ->
- AppDir = ?config(apps, Config),
-
- ASrc = <<"-module(a_src).\n-export([ok/0]).\nok() -> ok.\n">>,
- BSrc = <<"-module(b_src).\n-export([ok/0]).\nok() -> ok.\n">>,
- CSrc = <<"-module(c_src).\n-export([ok/0]).\nok() -> ok.\n">>,
-
- ok = filelib:ensure_dir(filename:join([AppDir, "more", "dummy"])),
- ok = filelib:ensure_dir(filename:join([AppDir, "ebin", "dummy"])),
- ok = file:write_file(filename:join([AppDir, "more", "a_src.erl"]), ASrc),
- ok = file:write_file(filename:join([AppDir, "more", "b_src.erl"]), BSrc),
- ok = file:write_file(filename:join([AppDir, "more", "c_src.erl"]), CSrc),
-
- Opts = dict:new(),
-
- rebar_erlc_compiler:compile(Opts,
- filename:join([AppDir, "more"]),
- filename:join([AppDir, "ebin"]),
- [filename:join([AppDir, "more", "a_src.erl"]),
- filename:join([AppDir, "more", "b_src.erl"]),
- filename:join([AppDir, "more", "c_src.erl"])]),
-
- EbinDir = filename:join([AppDir, "ebin"]),
- true = filelib:is_file(filename:join([EbinDir, "a_src.beam"])),
- true = filelib:is_file(filename:join([EbinDir, "b_src.beam"])),
- true = filelib:is_file(filename:join([EbinDir, "c_src.beam"])).
-