0

I have just installed Activestate Perl 5.24.3 on Windows 7 PC.

I am able to instal with ppm. Installed also CPAN.

But - I fail to launch the CPAN shell on CMD (DOS command line).

Here is whan I get when trying to invoke the cpan shell in CMD:

C:\Users\orenm>cpan
Cwd object version 3.63_01 does not match bootstrap parameter 3.74 at C:/Perl64/lib/DynaLoader.pm line 211.
Compilation failed in require at C:/Perl64/site/lib/File/Spec/Win32.pm line 5.
BEGIN failed--compilation aborted at C:/Perl64/site/lib/File/Spec/Win32.pm line5.
Compilation failed in require at C:/Perl64/site/lib/File/Spec.pm line 21.
Compilation failed in require at C:/Perl64/site/lib/CPAN.pm line 10.
BEGIN failed--compilation aborted at C:/Perl64/site/lib/CPAN.pm line 10.
Compilation failed in require at C:/Perl64/site/lib/App/Cpan.pm line 288.
BEGIN failed--compilation aborted at C:/Perl64/site/lib/App/Cpan.pm line 288.
Compilation failed in require at C:\Perl64\site\bin/cpan line 7.
BEGIN failed--compilation aborted at C:\Perl64\site\bin/cpan line 7.

C:\Users\orenm>

This also happens when trying to use the C:\Perl64\bin\cpan.bat .

Oren Maurer
  • 179
  • 2
  • 6
  • Cwd has a pure Perl component (Cwd.pm) and a binary component (Cwd.dll). The two components being loaded are from different versions of the module. You have a messed up installation, or you are telling Perl to look for modules in places where it shouldn't. – ikegami Jul 05 '18 at 05:22
  • Where do I check it? - I mean if I tell Perl to look for modules in places where it shouldn't. – Oren Maurer Jul 05 '18 at 05:45
  • 1
    Are the `PERL5LIB` or `PERLLIB` env vars set? – ikegami Jul 05 '18 at 05:47
  • No, I do not see these env vars. I am looking on: Control Panel\All Control Panel Items\System System Properties -> Advanced -> Environment Variables – Oren Maurer Jul 05 '18 at 05:56
  • 1
    More definitely, just type `set | find "PERL"` from the cmd in the console from which you run `cpan`. It's probably not going to give you anything different though, leaving the other option: A messed up Perl directory. – ikegami Jul 05 '18 at 05:57
  • You are right, it gives nothing: `C:\Users\orenm> set | find "PERL" C:\Users\orenm>` This means... what? Do I need to do 'Remove' and install again? – Oren Maurer Jul 05 '18 at 06:03
  • Let us [continue this discussion in chat](https://chat.stackoverflow.com/rooms/174381/discussion-between-oren-maurer-and-ikegami). – Oren Maurer Jul 05 '18 at 06:10
  • Do `where perl` and `where cpan` refer to the same place? – mob Jul 06 '18 at 00:35

1 Answers1

1

Well - solved. :) As ikegami noted - I probably messed up the installation.

I have managed to solve this by doing the following:

  1. Choosing the "Remove" option of the ActivePerl installer,
  2. Move aside the C:\Perl64\ directory, I mean - rename it.
  3. I verified the I don't have Perl in the system path variables. and:
  4. Activated the ActivePerl installer exe ("ActivePerl-5.24.3.2404-MSWin32-x64-404865.exe"), choosing the typical installation.
Oren Maurer
  • 179
  • 2
  • 6