httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rob Hartill <r...@imdb.com>
Subject pr#1581 workaround (fwd)
Date Sat, 20 Dec 1997 16:37:20 GMT
---------- Forwarded message ----------
Date: Fri, 19 Dec 1997 21:34:29 -0500
From: Harald Merk <hmerk@ucs.att.com>
To: apache-bugs@apache.org
Subject: pr#1581 workaround

The standars runperl.bat wrapper does not work via Apache. The problem
is with the statement "$0 =~ s|\.bat||i;". $0 is truncated to the
directory. Assiging $0 to annother variable and replacing all occurances
of $0 with that variable solves the problem.

Please post this to NetNews as I do not have access to it.

Here is the beginning of the script:
@rem = '--*-Perl-*--
@echo off
perl -x -S %0 %1 %2 %3 %4 %5 %6 %7 %8 %9
goto endofperl
@rem ';
#!perl -w
#line 8
$0 =~ s|\.bat||i;
unless (-f $0) {
    $0 =~ s|.*[/\\]||;
    for (".", split ';', $ENV{PATH}) {
 $_ = "." if $_ eq "";
 $0 = "$_/$0" , goto doit if -f "$_/$0";
    }
    die "`$0' not found.\n";
}
doit: exec "perl", "-x", $0, @ARGV;
die "Failed to exec `$0': $!";
__END__

=head1 NAME
================= remainder omitted ============



Mime
View raw message