From 95a54e26db826c8d3a10aea4982dd0de7291f424 Mon Sep 17 00:00:00 2001 From: Eric B Merritt Date: Sun, 7 Apr 2013 21:03:43 -0700 Subject: Don't run dialyzer on R14 and below Its too slow and the build fails on travis --- Makefile | 25 ++++++++++++++++++++++--- 1 file changed, 22 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 55565b0..a2eeaf9 100644 --- a/Makefile +++ b/Makefile @@ -35,6 +35,24 @@ ifeq ($(REBAR),) $(error "Rebar not available on this system") endif +# ============================================================================= +# Handle version discovery +# ============================================================================= + +# We have a problem that we only have 10 minutes to build on travis +# and those travis boxes are quite small. This is ok for the fast +# dialyzer on R15 and above. However on R14 and below we have the +# problem that travis times out. The code below lets us not run +# dialyzer on R14 +OTP_VSN=$(shell erl -noshell -eval 'io:format("~p", [erlang:system_info(otp_release)]), erlang:halt(0).' | perl -lne 'print for /R(\d+).*/g') +TRAVIS_SLOW=$(shell expr $(OTP_VSN) \<= 14 ) + +ifeq ($(TRAVIS_SLOW), 0) +DIALYZER=$(shell which dialyzer) +else +DIALYZER=: not running dialyzer on R14 +endif + .PHONY: all compile doc clean test dialyzer typer shell distclean pdf \ update-deps escript clean-common-test-data rebuild @@ -75,13 +93,14 @@ ct: compile clean-common-test-data test: compile eunit ct $(DEPS_PLT): - @echo Building local plt at $(DEPS_PLT) + @echo Building local erts plt at $(DEPS_PLT) @echo - dialyzer --output_plt $(DEPS_PLT) --build_plt \ + $(DIALYZER) --output_plt $(DEPS_PLT) --build_plt \ --apps erts kernel stdlib -r deps dialyzer: $(DEPS_PLT) - dialyzer --fullpath --plt $(DEPS_PLT) -I include -Wrace_conditions -r ./ebin + $(DIALYZER) --fullpath --plt $(DEPS_PLT) \ + -I include -Wrace_conditions -r ./ebin typer: typer --plt $(DEPS_PLT) -r ./src -- cgit v1.2.3 From 0759b8fbb928ee07827f1596035f6df7b4c351a3 Mon Sep 17 00:00:00 2001 From: Tristan Sloughter Date: Mon, 8 Apr 2013 18:03:14 -0500 Subject: remove dialyzer and test from all since we run travis on PRs --- Makefile | 2 +- README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index a2eeaf9..2fc0038 100644 --- a/Makefile +++ b/Makefile @@ -56,7 +56,7 @@ endif .PHONY: all compile doc clean test dialyzer typer shell distclean pdf \ update-deps escript clean-common-test-data rebuild -all: deps compile escript dialyzer test +all: deps compile escript # ============================================================================= # Rules to build the system diff --git a/README.md b/README.md index bff3bcf..b235f37 100644 --- a/README.md +++ b/README.md @@ -25,7 +25,7 @@ additional specification information for releases. To build relcool and generate a standalone escript executable: - $ make escript + $ make This creates the executable `relcool`. -- cgit v1.2.3