1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159
|
### SPAR <http://www.cpan.org/scripts/>
### 26 644 1067451874 1350842084 makepp_test_script.pl
#
# Test various kinds of fake signatures that we generate using the
# --assume-new, --assume-old, and -n option.
#
sub doit {
my( $sf, $opt, $bl, $af, $nowait ) = @_;
c_echo $sf, '-osourcefile' if $sf;
c_grep '/^&(?:cat|sed)/', "-Ii$ENV{PERL} $makepp_path -r $opt|", "-obuild_log_$bl";
c_cp allfiles => "allfiles_$bl" if $af;
wait_timestamp 'allfiles' if !$nowait;
}
doit 'source_original', '', '0';
doit 0, '-W f', 'W_f', 1;
c_touch 'h';
doit 'source_modified', '-o sourcefile', 'o_sourcefile', 1;
c_echo 'g_modified', '-og';
doit 'source_original', '--dont-build g', 'dont_build_g', 1;
doit 0, '-n', 'n', 1, 1;
1;
### 31 644 1118567371 1059888249 Makeppfile
#
# Makefile that is used to test the various kinds of fake signatures that
# we use: --assume-new, --assume-old, and -n.
#
$(phony all): allfiles
allfiles: ab ac bc
&cat $^ -o $@
a : e f : build_check target_newer # Make sure target_newer supports it too.
&cat $^ -o $@
b : g h
&cat $^ -o $@
c : f h
&cat $^ -o $@
# Sourcefile is built by makepp_test_script.
e f g h: sourcefile
&sed "s/$$/ $@/" sourcefile -o $@
ab: a b
&cat $^ -o $@
bc: b c
&cat $^ -o $@
ac: a c
&cat $^ -o $@
### D 755 1067451874 1060021421 answers
### 12 644 1067451874 1060021408 answers/allfiles_n
source_original e
source_original f
g_modified
source_original h
source_original e
source_original f
source_original f
source_original h
g_modified
source_original h
source_original f
source_original h
### 6 644 1067451874 1060021403 answers/build_log_W_f
&cat e f -o a
&cat a b -o ab
&cat f h -o c
&cat a c -o ac
&cat b c -o bc
&cat ab ac bc -o allfiles
### 7 644 1067451874 1060021405 answers/build_log_o_sourcefile
&sed "s/$/ h/" sourcefile -o h
&cat g h -o b
&cat a b -o ab
&cat f h -o c
&cat a c -o ac
&cat b c -o bc
&cat ab ac bc -o allfiles
### 12 644 1067451874 1060021408 answers/allfiles_dont_build_g
source_original e
source_original f
g_modified
source_original h
source_original e
source_original f
source_original f
source_original h
g_modified
source_original h
source_original f
source_original h
### 11 644 1067451874 1060021401 answers/build_log_0
&sed "s/$/ e/" sourcefile -o e
&sed "s/$/ f/" sourcefile -o f
&cat e f -o a
&sed "s/$/ g/" sourcefile -o g
&sed "s/$/ h/" sourcefile -o h
&cat g h -o b
&cat a b -o ab
&cat f h -o c
&cat a c -o ac
&cat b c -o bc
&cat ab ac bc -o allfiles
### 5 644 1067451874 1060021408 answers/build_log_n
&sed "s/$/ g/" sourcefile -o g
&cat g h -o b
&cat a b -o ab
&cat b c -o bc
&cat ab ac bc -o allfiles
### 1 644 1067451874 1190053829 answers/n_files
5 1 0
### 12 644 1067451874 1060021405 answers/allfiles_o_sourcefile
source_original e
source_original f
source_original g
source_modified h
source_original e
source_original f
source_original f
source_modified h
source_original g
source_modified h
source_original f
source_modified h
### 10 644 1067451874 1060021408 answers/build_log_dont_build_g
&sed "s/$/ e/" sourcefile -o e
&sed "s/$/ f/" sourcefile -o f
&cat e f -o a
&sed "s/$/ h/" sourcefile -o h
&cat g h -o b
&cat a b -o ab
&cat f h -o c
&cat a c -o ac
&cat b c -o bc
&cat ab ac bc -o allfiles
### 12 644 1067451874 1060021403 answers/allfiles_W_f
source_original e
source_original f
source_original g
source_original h
source_original e
source_original f
source_original f
source_original h
source_original g
source_original h
source_original f
source_original h
|