diff options
author | Paul Smith <psmith@gnu.org> | 2002-09-04 07:26:19 +0000 |
---|---|---|
committer | Paul Smith <psmith@gnu.org> | 2002-09-04 07:26:19 +0000 |
commit | 988deb489b89889b97f82e3095d267d09ff7e7ab (patch) | |
tree | 8127d7aa6cfedde3f284f5c6ae77e4f2eefee59e /tests/scripts/misc | |
parent | d2429d7508169501d2dfeefca5608005142fe236 (diff) | |
download | gunmake-988deb489b89889b97f82e3095d267d09ff7e7ab.tar.gz |
Fix for complex situations where directories are declared as prerequisites.
Info on this fix from barkalow@reputation.com: thanks!
Some updates/cleanups of some of the tests; added a forgotten -t test, etc.
Diffstat (limited to 'tests/scripts/misc')
-rw-r--r-- | tests/scripts/misc/general4 | 31 | ||||
-rw-r--r-- | tests/scripts/misc/version | 35 |
2 files changed, 31 insertions, 35 deletions
diff --git a/tests/scripts/misc/general4 b/tests/scripts/misc/general4 new file mode 100644 index 0000000..dd77f53 --- /dev/null +++ b/tests/scripts/misc/general4 @@ -0,0 +1,31 @@ +# -*-perl-*- + +$description = "\ +This tests random features of make's algorithms, often somewhat obscure, +which have either broken at some point in the past or seem likely to +break."; + +open(MAKEFILE,"> $makefile"); + +# The contents of the Makefile ... + +print MAKEFILE <<'EOF'; +# Make sure that subdirectories built as prerequisites are actually handled +# properly. + +all: dir/subdir/file.a + +dir/subdir: ; @echo mkdir -p dir/subdir + +dir/subdir/file.b: dir/subdir ; @echo touch dir/subdir/file.b + +dir/subdir/%.a: dir/subdir/%.b ; @echo cp $< $@ +EOF + +close(MAKEFILE); + +&run_make_with_options($makefile,"",&get_logfile); +$answer = "mkdir -p dir/subdir\ntouch dir/subdir/file.b\ncp dir/subdir/file.b dir/subdir/file.a\n"; +&compare_output($answer,&get_logfile(1)); + +1; diff --git a/tests/scripts/misc/version b/tests/scripts/misc/version deleted file mode 100644 index d49b153..0000000 --- a/tests/scripts/misc/version +++ /dev/null @@ -1,35 +0,0 @@ -$description = "The following test creates a makefile to ... \n"; - -$details = "Fill in Later\n"; - -open(MAKEFILE,"> $makefile"); - -# The Contents of the MAKEFILE ... - -print MAKEFILE "all: \n"; - -# END of Contents of MAKEFILE - -close(MAKEFILE); - -&run_make_with_options($makefile,"-v",&get_logfile,0); - -# This tells the test driver that the perl test script executed properly. -1; - - - - - - - - - - - - - - - - - |