3 # $Cambridge: exim/test/patchexim,v 1.1 2006/02/06 16:07:10 ph10 Exp $
5 ###############################################################################
6 # This is an auxiliary script that is part of the Exim test suite. It must be #
7 # run as root, and is normally called from the main controlling script. Its #
8 # job is to make a copy of Exim, suitably patched so that it can run in the #
9 # test harness. See further comments in the main script. #
11 # The only argument to this script is the name of the Exim binary that is to #
12 # be copied. The script must be run in the correct current directory. #
13 ###############################################################################
15 open(IN, "$ARGV[0]") || die "** Failed to open $ARGV[0]: $!\n";
16 open(OUT, ">eximdir/exim") || die "** Failed to open eximdir/exim: $!\n";
20 s/>>>running<<</<<<testing>>>/;
21 s/(\d+\.\d+(?:\.\d+)?(-RC\d+)?\0<<eximversion>>)/"x.yz\0" . ("*" x (length($1) - 5))/e;
28 chmod 04755, "eximdir/exim";
30 # End of patchexim script