diff options
author | Paweł Chmielowski <pchmielowski@process-one.net> | 2017-09-26 18:32:37 +0300 |
---|---|---|
committer | Paweł Chmielowski <pchmielowski@process-one.net> | 2017-09-26 18:32:37 +0300 |
commit | 05feab35c4169ec5cf9c4d0fba8f56075e3d0152 (patch) | |
tree | e27203677401d2bfc1d0e53d421869073ed07c5d /rebar.config.script | |
parent | 2198fbce972cc4b3ae920ab0d78e05d732cefd0e (diff) |
Call earlier deps configure scripts durring compilation
Diffstat (limited to 'rebar.config.script')
-rw-r--r-- | rebar.config.script | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/rebar.config.script b/rebar.config.script index f31ceaae2..219514a2f 100644 --- a/rebar.config.script +++ b/rebar.config.script @@ -255,9 +255,9 @@ CtParams = fun(CompileOpts) -> GenDepConfigureLine = fun(DepPath, Flags) -> - ["sh -c 'if test ! -f ",DepPath,"config.status -o ", - "config.status -nt ",DepPath,"config.status; ", - "then (cd ", DepPath, " && ", + ["sh -c 'if test ! -f config.status -o ", + "../../config.status -nt config.status; ", + "then (", "CFLAGS=\"", CFlags,"\" ", "CPPFLAGS=\"", CPPFlags, "\" " "LDFLAGS=\"", LDFlags, "\"", @@ -269,8 +269,8 @@ GenDepsConfigure = fun(Hooks) -> lists:map(fun({Pkg, Flags}) -> DepPath = ResolveDepPath("deps/" ++ Pkg ++ "/"), - {'compile', - lists:flatten(GenDepConfigureLine(DepPath, Flags))} + {add, list_to_atom(Pkg), [{pre_hooks, {'compile', + lists:flatten(GenDepConfigureLine(DepPath, Flags))}}]} end, Hooks) end, @@ -326,7 +326,7 @@ Rules = [ AppendList([{coveralls, ".*", {git, "https://github.com/markusn/coveralls-erl.git", "master"}}]), []}, {[post_hooks], [cover_enabled], os:getenv("TRAVIS") == "true", AppendList2(TravisPostHooks), [], false}, - {[pre_hooks], [post_hook_configure], true, + {[overrides], [post_hook_configure], true, AppendList2(GenDepsConfigure), [], []}, {[ct_extra_params], [eunit_compile_opts], true, AppendStr2(CtParams), "", []}, |