aboutsummaryrefslogtreecommitdiffstats
path: root/test/core_deps.mk
diff options
context:
space:
mode:
authorLoïc Hoguin <[email protected]>2015-09-29 18:32:39 +0200
committerLoïc Hoguin <[email protected]>2015-09-29 18:32:39 +0200
commit7cac447fb151e57c49660a76a6eb4ccca019ff58 (patch)
tree0c9b78783650436c9e40062da64da70197a1b371 /test/core_deps.mk
parent9d33c41efaa778102c7606cfb19f2523fdba1c97 (diff)
downloaderlang.mk-7cac447fb151e57c49660a76a6eb4ccca019ff58.tar.gz
erlang.mk-7cac447fb151e57c49660a76a6eb4ccca019ff58.tar.bz2
erlang.mk-7cac447fb151e57c49660a76a6eb4ccca019ff58.zip
Add a test for NO_AUTOPATCH_ERLANG_MK
Diffstat (limited to 'test/core_deps.mk')
-rw-r--r--test/core_deps.mk21
1 files changed, 20 insertions, 1 deletions
diff --git a/test/core_deps.mk b/test/core_deps.mk
index 1223187..5b928f1 100644
--- a/test/core_deps.mk
+++ b/test/core_deps.mk
@@ -1,6 +1,6 @@
# Core: Packages and dependencies.
-CORE_DEPS_CASES = apps apps-conflict apps-deep-conflict apps-dir apps-new-app apps-new-lib apps-new-tpl apps-only build-c-8cc build-c-imagejs build-erl build-js dep-commit dir doc fetch-cp fetch-custom fetch-fail-bad fetch-fail-unknown fetch-git fetch-hex fetch-hg fetch-legacy fetch-svn ignore no-autopatch no-autopatch-rebar order-first order-top otp pkg rel search shell test
+CORE_DEPS_CASES = apps apps-conflict apps-deep-conflict apps-dir apps-new-app apps-new-lib apps-new-tpl apps-only build-c-8cc build-c-imagejs build-erl build-js dep-commit dir doc fetch-cp fetch-custom fetch-fail-bad fetch-fail-unknown fetch-git fetch-hex fetch-hg fetch-legacy fetch-svn ignore no-autopatch no-autopatch-erlang-mk no-autopatch-rebar order-first order-top otp pkg rel search shell test
CORE_DEPS_TARGETS = $(addprefix core-deps-,$(CORE_DEPS_CASES))
CORE_DEPS_CLEAN_TARGETS = $(addprefix clean-,$(CORE_DEPS_TARGETS))
@@ -929,6 +929,25 @@ core-deps-no-autopatch: build clean-core-deps-no-autopatch
$i "Check that Cowlib was not autopatched"
$t grep -q Hoguin $(APP)/deps/cowlib/erlang.mk
+core-deps-no-autopatch-erlang-mk: build clean-core-deps-no-autopatch-erlang-mk
+
+ $i "Bootstrap a new OTP library named $(APP)"
+ $t mkdir $(APP)/
+ $t cp ../erlang.mk $(APP)/
+ $t $(MAKE) -C $(APP) -f erlang.mk bootstrap-lib $v
+
+ $i "Add Cowlib to the list of dependencies and set NO_AUTOPATCH_ERLANG_MK=1"
+ $t perl -ni.bak -e 'print;if ($$.==1) {print "DEPS = cowlib\nNO_AUTOPATCH_ERLANG_MK = 1\n"}' $(APP)/Makefile
+
+ $i "Build the application"
+ $t $(MAKE) -C $(APP) $v
+
+ $i "Check that all dependencies were fetched"
+ $t test -d $(APP)/deps/cowlib
+
+ $i "Check that Erlang.mk was not autopatched"
+ $t grep -q Hoguin $(APP)/deps/cowlib/erlang.mk
+
core-deps-no-autopatch-rebar: build clean-core-deps-no-autopatch-rebar
$i "Bootstrap a new OTP library named $(APP)"