From 6469810f6a6c260f9afe551f64428890cbb5131c Mon Sep 17 00:00:00 2001 From: Jarkko Hietaniemi Date: Sun, 25 Nov 2001 04:20:02 +0000 Subject: [PATCH] Now is Solaris if you start the t/perl in the t/ as "./perl", the $^X will be "../perl", not "./perl". p4raw-id: //depot/perl@13255 --- t/lib/1_compile.t | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/t/lib/1_compile.t b/t/lib/1_compile.t index 51d4d6a..af2c168 100644 --- a/t/lib/1_compile.t +++ b/t/lib/1_compile.t @@ -1,7 +1,13 @@ #!./perl BEGIN { - chdir '..' if -d '../pod' && -d '../t'; + if (-d '../pod' && -d '../t') { + require File::Spec; + my ($v,$d,$f) = File::Spec->splitpath($^X); + $^X = File::Spec->catfile(File::Spec->curdir, $f) + if $^X eq File::Spec->catfile(File::Spec->updir, $f); + chdir '..'; + } @INC = 'lib'; } -- 2.7.4