11 my $DIR_AD=dirname($0)."/ad";
14 chdir $DIR_AD or die "chdir $DIR_AD: $!";
21 open(M4,"-|","m4 --prefix-builtins --synclines main") or die "m4 run: $!";
26 do { $files{$1}=undef; next; } if /^#\s*line\s+\d+\s+"(.*)"$/;
33 $patt=qr @^http://($patt).*\n$@;
35 while ($_=shift @got || <>) {
36 while (my($file,$old)=each %files) {
37 my $new=(stat $file)[9];
39 next if !defined $old || $old==$new;
43 s@$patt@http://localhost/cgi-bin/redirector-ad.cgi?$^R\n@;