Subject: | Some tests run with the wrong perl executable |
On my smokers I see test failures like this:
...
Can't locate Text/CSV.pm in @INC (you may need to install the Text::CSV module) (@INC contains: examples//../lib blib/lib blib/arch /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.28.1 /usr/local/share/perl/5.28.1 /usr/lib/x86_64-linux-gnu/perl5/5.28 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.28 /usr/share/perl/5.28 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base .) at examples//../lib/FP/Text/CSV.pm line 90.
BEGIN failed--compilation aborted at examples//../lib/FP/Text/CSV.pm line 90.
Compilation failed in require at examples/csv_to_xml line 39.
BEGIN failed--compilation aborted at examples/csv_to_xml line 39.
only got 0 bytes instead of 210 at ./meta/test.pl line 16.
t/csv_to_xml .......................
Dubious, test returned 255 (wstat 65280, 0xff00)
No subtests run
... (and more of these) ...
Probably the problem is that csv_to_xml runs with the wrong perl, possibly with the first perl in the user's path (in my case this is /usr/bin/perl), or using a fixed shebang (possibly also /usr/bin/perl). But this is not the perl which is used to build & test the distribution, so it looks like there are missing dependencies.
Usually the fix is to call such scripts with $^X, which would pick the correct perl executable.