summaryrefslogtreecommitdiff
path: root/utils/perlivp.PL
diff options
context:
space:
mode:
Diffstat (limited to 'utils/perlivp.PL')
-rw-r--r--utils/perlivp.PL8
1 files changed, 8 insertions, 0 deletions
diff --git a/utils/perlivp.PL b/utils/perlivp.PL
index f5963e8957..91a2e4f3fd 100644
--- a/utils/perlivp.PL
+++ b/utils/perlivp.PL
@@ -135,6 +135,14 @@ else {
}
$tests_total++;
+# We have the right perl and version, so now reset @INC so we ignore
+# PERL5LIB and '.'
+{
+ local $ENV{PERL5LIB};
+ my $perl_V = qx($perlpath -V);
+ $perl_V =~ s{.*\@INC:\n}{}ms;
+ @INC = grep { length && $_ ne '.' } split ' ', $perl_V;
+}
print "## Checking roots of the Perl library directory tree via variable `\@INC'.\n" if $opt{'p'};