From 3b232315db53cbae26621fcac0ca0fe7e382dde1 Mon Sep 17 00:00:00 2001 From: Seth Falcon Date: Mon, 22 Oct 2012 14:42:12 -0700 Subject: [PATCH] Remove hard dependency on proper Running "make eunit" will now download proper into deps and ensure it is on the code path. Projects that depend on jiffy will no longer pick up a transitive dependency on proper. When the eunit target is run, proper will be cloned into deps/ if not already found and compiled (also if not already compiled). Also includes a few Makefile tweaks: * Add distclean target * Add .PHONY for Makefile target hygeine --- Makefile | 16 +++++++++++++--- rebar.config | 4 ---- 2 files changed, 13 insertions(+), 7 deletions(-) diff --git a/Makefile b/Makefile index 7ceefbe..19007f5 100644 --- a/Makefile +++ b/Makefile @@ -8,6 +8,8 @@ clean: rm -rf .eunit rm -f test/*.beam +distclean: clean + rm -rf deps depends: @if test ! -d ./deps; then \ @@ -25,13 +27,21 @@ etap: test/etap.beam test/util.beam prove test/*.t -eunit: - $(REBAR) eunit skip_deps=true +eunit: deps/proper/ebin/proper.beam + ERL_FLAGS='-pa deps/proper/ebin' $(REBAR) eunit skip_deps=true -check: build etap eunit +deps/proper/ebin/proper.beam: deps/proper + cd deps/proper; $(REBAR) compile + +deps/proper: + mkdir -p deps + cd deps; git clone git://github.com/manopapad/proper.git +check: build etap eunit + %.beam: %.erl erlc -o test/ $< +.PHONY: all clean depends build etap eunit proper check diff --git a/rebar.config b/rebar.config index d6eb828..fe9e06a 100644 --- a/rebar.config +++ b/rebar.config @@ -1,7 +1,3 @@ -{deps, [ - {proper, ".*", {git, "https://github.com/manopapad/proper.git", "master"}} -]}. - {port_specs, [{"priv/jiffy.so", ["c_src/*.c"]}]}. {port_env, [