Intrepid has asked for the wisdom of the Perl Monks concerning the following question:

Hi Monks. I don't know if anyone can help me with this, but I'll ask anyhow.

I'm doing this on the commandline:


$ PERL5LIB=~/build/perl-testing-libs/lib/perl5 cpanm --self-contained \
--exclude-vendor -L ~/build/perl-testing-libs --wget --skip-satisfied \
--interactive --verbose YAML::LibYAML

The resulting message is


! Installing the dependencies failed: Module 'Test::More' is not installed
! Bailing out the installation for File-Temp-0.2312.
! Installing the dependencies failed: Module 'File::Temp' is not installed

When I try to build the two required modules alone, I can't get a succcessful installation. What's going on?

EDIT

Sorry,I was tired and in a hurry and didn't give much contextual info. My System and my Perl are:
OS: CYGWIN_NT-10.0-26200; cpu type: x86_64; |12| cores, cpus present: |1|
Perl version v5.40.3, CygPerl.

    – Soren

Apr 28, 2026 at 21:46 UTC

A just machine to make big decisions
Programmed by fellows (and gals) with compassion and vision
We'll be clean when their work is done
We'll be eternally free yes, and eternally young
Donald Fagen —> I.G.Y.
(Slightly modified for inclusiveness)

  • Comment on Installation of 2 module prerequisites failing - using cpanm

Replies are listed 'Best First'.
Re: Installation of 2 module prerequisites failing - using cpanm
by bliako (Abbot) on Apr 29, 2026 at 09:14 UTC
    When I try to build the two required modules alone, I can't get a succcessful installation.

    well, show us the errors of installing the 2 required modules. Unless you mean you installed the 2 modules successfully but still no joy for the target module. In which case, check your include dirs or whether you used different perl versions (via perlbrew), etc. etc. Check if the path ~/build/perl-testing-libs/lib/perl5 contains the 2 dependencies. Should that -L contain lib/perl5? I am not acquainted with this option.

Re: Installation of 2 module prerequisites failing - using cpanm
by tobyink (Canon) on Apr 29, 2026 at 10:50 UTC

    File::Temp has been bundled with Perl since Perl 5.6.1 was released more than a quarter of a century ago.

    Test::More has been included since 5.6.2, almost as long ago.

    If your Perl installation cannot find these modules, there are likely deeper issues at play.

      Hi you haven't been here for a while, welcome back! :)

      so you know

      > likely deeper issues at play

      Simultaneous Perl installations and messed up environments are a recurring theme in many posts of this particular monk.

      See threads by this OP (click search)

      Cheers Rolf
      (addicted to the Perl Programming Language :)
      see Wikisyntax for the Monastery

      I think part of it is the use of --self-contained, while also not having the core modules available maybe due to overriding PERL5LIB and Perl itself not supplying the correct path, maybe due to running a Win32 Perl while expecting a Cygwin Perl.