/[make]/make/tests/scripts/misc/general4
ViewVC logotype

Diff of /make/tests/scripts/misc/general4

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.3 by psmith, Mon Feb 28 07:48:23 2005 UTC revision 1.4 by psmith, Mon Oct 24 13:01:41 2005 UTC
# Line 5  This tests random features of make's alg Line 5  This tests random features of make's alg
5  which have either broken at some point in the past or seem likely to  which have either broken at some point in the past or seem likely to
6  break.";  break.";
7    
8  open(MAKEFILE,"> $makefile");  run_make_test('
 print MAKEFILE <<'EOF';  
9  # Make sure that subdirectories built as prerequisites are actually handled  # Make sure that subdirectories built as prerequisites are actually handled
10  # properly.  # properly.
11    
# Line 16  dir/subdir: ; @echo mkdir -p dir/subdir Line 15  dir/subdir: ; @echo mkdir -p dir/subdir
15    
16  dir/subdir/file.b: dir/subdir ; @echo touch dir/subdir/file.b  dir/subdir/file.b: dir/subdir ; @echo touch dir/subdir/file.b
17    
18  dir/subdir/%.a: dir/subdir/%.b ; @echo cp $< $@  dir/subdir/%.a: dir/subdir/%.b ; @echo cp $< $@',
19  EOF                '', "mkdir -p dir/subdir\ntouch dir/subdir/file.b\ncp dir/subdir/file.b dir/subdir/file.a\n");
 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));  
20    
21  # Test implicit rules  # Test implicit rules
22    
# Line 47  fox: baz Line 41  fox: baz
41                'done bar');                'done bar');
42  unlink('bar');  unlink('bar');
43    
44    
45    # Test implicit rules with '$' in the name (see se_implicit)
46    
47    run_make_test(q!
48    %.foo : baz$$bar ; @echo 'done $<'
49    %.foo : bar$$baz ; @echo 'done $<'
50    test.foo:
51    fox: baz
52    .DEFAULT baz$$bar bar$$baz: ; @echo '$@'
53    !,
54                  '',
55                  'done bar');
56    
57  1;  1;

Legend:
Removed from v.1.3  
changed lines
  Added in v.1.4

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26