/[make]/make/tests/scripts/options/dash-B
ViewVC logotype

Diff of /make/tests/scripts/options/dash-B

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

revision 1.2 by psmith, Tue Sep 10 22:23:20 2002 UTC revision 1.3 by psmith, Mon Feb 28 09:41:25 2005 UTC
# Line 8  Invoke make once, so it builds everythin Line 8  Invoke make once, so it builds everythin
8  that nothing is built.  Then invoke it with -B and verify that everything  that nothing is built.  Then invoke it with -B and verify that everything
9  is built again.";  is built again.";
10    
11  open(MAKEFILE,"> $makefile");  &touch('bar.x');
12    
13  print MAKEFILE <<'EOF';  run_make_test('
14  .SUFFIXES:  .SUFFIXES:
15    
16  .PHONY: all  .PHONY: all
# Line 19  all: foo Line 19  all: foo
19  foo: bar.x  foo: bar.x
20          @echo cp $< $@          @echo cp $< $@
21          @echo "" > $@          @echo "" > $@
22  EOF  ',
23                  '', 'cp bar.x foo');
24    
25  close(MAKEFILE);  run_make_test(undef, '', "#MAKE#: Nothing to be done for `all'.");
26    run_make_test(undef, '-B', 'cp bar.x foo');
27    
28    # Put the timestamp for foo into the future; it should still be remade.
29    
30    utouch(1000, 'foo');
31    run_make_test(undef, '', "#MAKE#: Nothing to be done for `all'.");
32    run_make_test(undef, '-B', 'cp bar.x foo');
33    
 &touch('bar.x');  
34    
35  &run_make_with_options($makefile, '', &get_logfile);  # Clean up
 $answer = "cp bar.x foo\n";  
 &compare_output($answer, &get_logfile(1));  
   
 &run_make_with_options($makefile, '', &get_logfile);  
 $answer = "$make_name: Nothing to be done for `all'.\n";  
 &compare_output($answer, &get_logfile(1));  
   
 &run_make_with_options($makefile, '-B', &get_logfile);  
 $answer = "cp bar.x foo\n";  
 &compare_output($answer, &get_logfile(1));  
36    
37  unlink('bar.x', 'foo') unless $keep;  rmfiles('bar.x', 'foo');
38    
39  1;  1;

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

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