summaryrefslogtreecommitdiff
path: root/tests/scripts
diff options
context:
space:
mode:
authorPaul Smith <psmith@gnu.org>2013-07-09 19:14:40 -0400
committerPaul Smith <psmith@gnu.org>2013-07-09 19:14:40 -0400
commit5601726151b3856ad26433d632392904ec059368 (patch)
tree04b9fed5f0a9ccb21cf139e3cd390ce49729e7a7 /tests/scripts
parent9453a7451d66ee1ea5762a75161bf8a818c01a1f (diff)
downloadgunmake-5601726151b3856ad26433d632392904ec059368.tar.gz
Keep a local count of the max dependency list size.
This global variable could be modified during recursion so keep our own local copy to compare against.
Diffstat (limited to 'tests/scripts')
-rw-r--r--tests/scripts/features/se_implicit22
1 files changed, 22 insertions, 0 deletions
diff --git a/tests/scripts/features/se_implicit b/tests/scripts/features/se_implicit
index e9acb2f..0a31948 100644
--- a/tests/scripts/features/se_implicit
+++ b/tests/scripts/features/se_implicit
@@ -222,5 +222,27 @@ foo.o:
!,
'', "\n");
+# Test #10: Test second expansion with second expansion prerequisites
+# Ensures pattern_search() recurses with SE prereqs.
+touch('a');
+run_make_test(q!
+.SECONDEXPANSION:
+sim_base_rgg := just_a_name
+sim_base_src := a
+sim_base_f := a a a
+sim_%.f: $${sim_$$*_f}
+ echo $@
+sim_%.src: $${sim_$$*_src}
+ echo $@
+sim_%: \
+ $$(if $$(sim_$$*_src),sim_%.src) \
+ $$(if $$(sim_$$*_f),sim_%.f) \
+ $$(if $$(sim_$$*_rgg),$$(sim_$$*_rgg).s)
+ echo $@
+!,
+ '-s sim_base', "#MAKE#: *** No rule to make target 'sim_base'. Stop.", 512);
+
+unlink('a');
+
# This tells the test driver that the perl test script executed properly.
1;