&run_make_with_options($makefile,"",&get_logfile,0);
-# Create the answer to what should be produced by this Makefile
$answer = "arg1 NOT equal arg2
arg2 equals arg5
arg3 NOT equal arg4
arg4 is defined
";
-# COMPARE RESULTS
-
&compare_output($answer,&get_logfile(1));
EOF
+close(MAKEFILE)
+
&run_make_with_options($makefile2,"",&get_logfile,0);
$answer = "DEF=yes DEF2=yes\n";
&compare_output($answer,&get_logfile(1));
EOF
+close(MAKEFILE);
+
&run_make_with_options($makefile2,"",&get_logfile,0);
$answer = "foo=f-ok bar=b-ok\nfoo=f-ok bar=b-ok\n";
&compare_output($answer,&get_logfile(1));
EOF
+close(MAKEFILE);
+
&run_make_with_options($makefile3,"",&get_logfile,0);
$answer = "foo=f-ok bar=b-ok\nfoo= bar=\n";
&compare_output($answer,&get_logfile(1));
foo: bar.x
@echo cp $< $@
- @touch $@
+ @echo "" > $@
EOF
close(MAKEFILE);
$(dir)/x.z $(dir)/y.z: $(dir)/%.z : $@.% $$@.% $$$@.% $$$$@.% $$(@D).% $$(@F).%
EOF
+close(MAKEFILE);
+
&run_make_with_options($makefile2, "$dir/foo $dir/bar", &get_logfile);
$answer = ".x\n$dir/foo.x\n\$.x\n\$@.x\n$dir.x\nfoo.x\n$dir/bar.x\nbar.x\n";
&compare_output($answer, &get_logfile(1));