I installed MinGW for installing perl modules from CPAN. after successful installation in C:/MinGW, I started msys.bat typed
cpan
cpan> install File::List
The module installed successfully. But it is not found in lib or site directory of c:/perl.
It is installed in C:\MinGW\msys\1.0\lib\perl5\site_perl\5.8\File instead.
How could I change the installation directory of CPAN modules to c:/perl/site or c:/perl/lib?
I used all default setting of MinGW. OS is Windows 7. Perl version 5.12.2.
"How could I change the installation directory of CPAN modules to c:/perl/site or c:/perl/lib?"
It's not clear to me why you would want to do that. If you used MinGW to install modules from CPAN, it is presumably because you want the advantages of the MinGW toolset (as described at
http://mingw.org/). And MinGW presumably knows what it is doing when it installs in the directory you cited.
If you really want to install to c:/perl/site or c:/perl/lib, you should probably use the cpan client that comes with Perl itself.
I figured out the problem. I don't have Microsoft Visual C++ redistributable 2008, 2010. I installed it and my problem is solved. May be Perl module builds which requires C compiler required this components.
Anyone ever have similar experience?
Related
I am using the windows 8 operating system and I am trying to install the WWW::Mechanize::Firefox module in ActiveState Perl, from CPAN. I have successfully downloaded and installed all the dependencies and also installed the MozRepl module on Firefox. I do not have noScript running on my firefox and hence I am assuming that Javascript is enabled across all files (I am not sure how or where to check that). Here is my error message when I try to install the module.
I also constantly receive this error throughout the installation - "Subroutine-MozRepl-Load Plugins redefined at line 104."
Any help is much appreciated ! Thank you !
EDIT - These are the errors -
As Kim suggested in comments, you will need Mozrepl and Firefox.
Please refer WWW::Mechanize::Firefox::Installation page for detailed instructions on how to install this module.
If you use ActiveStates package manager, you can find some pre-packaged but untested PPMs at https://github.com/Corion/www-mechanize-firefox/downloads .
I needed to use this module on Windows, and couldn't get it running with ActivePerl. So I installed http://strawberryperl.com/ and it worked. This version of perl seems to handle installs form the cpan command line utility better than Activestate, who expect you to use their perl package manager as the default module installer (and don't supply a dmake program). Strawberry Perl also comes with a C compiler so can build modules that are a mixture of Perl and C code.
And make sure mozrepl is running before you try to install.
I am a windows 7 (64 bit) user. I was trying to install Class::Inspector module in Perl. However it requred Nmake15.exe. I have tried to download the exe and when I run it, there is an pop up message stating that
The program or feature Nmake15.exe cannot start or run due to incompatibility with 64-bit versions of Windows
Could anyone advice on this? Thanks. This is a pre-requisite module required by SOAP::Lite.
nmake 1.5 is very old, and getting a modern version involves installing the massive Visual Studio suite. As an alternative, you can use dmake which works just as well.
In addition, your version of ActivePerl is quite out of date. I believe more recent versions now ship with a make program and will run much better on Windows.
Finally, Strawberry Perl is in many ways a better distribution of Perl on Windows. It comes with a complete Perl module build toolchain including dmake and a C compiler. You should be able to install most modules on CPAN using its preconfigured CPAN shell.
Class::Inspector is a pure-Perl module. Therefore, you could easily install it by copying the contents of the lib/ directory into one of your #INC paths.
This does not solve your problem with installing modules in general, though. That's why you should install a 64 bit version of nmake. By installing the Windows SDK, the nmake utility will be available at "C:\Program Files (x86)\Microsoft Visual Studio...\VC\bin\amd64\nmake.exe" (microsoft.com).
At first,I tried to use ppm and cpanm to install Tk module.But failed to download whth the reason which i don't konw(yet i can install image module) .So I tried another way.I downloaded the Tk-804.030 from the cpan website.And unpacked it.Then I type "perl makefile.pl" in the cmd, howerver, shit happens.There were so many errors.And i remenbered to read the README.txt, so i found the following which make me frustrated.
When you install ActivePerl, it provides patched C runtime as PerlCRT.dll
which it installs in the "system32" directory.
This needs "administrator" rights on NT.
It also provides the import library PerlCRT.lib, but this is installed
in an odd location e.g. C:\ActivePerl\lib\CORE\PerlCRT.lib
where it is not found by MakeMaker or VC++.I copied it to C:\VisualStudio\VC98\lib\PerlCRT.lib
(Your paths may vary dependinh where you installed ActivePerl and VC++.)
I could not find the PerlCRT.dll and PerlCRT.lib in my computer, i googled and found PerlCRT.dll which could be downloaded, but i counld find PerlCRT.lib to download.i don't kown how to do it, i really need some help.It couldn't be better if you can tell me the whole installing procedure. ( I'm new to Perl, and I use Win7, visual studio 2012 and MinGW as well)
See PPM Tk info page, the distro fails to build on the current versions of ActiveState Perl for Windows. You can add the 3rd party Bribes repository, Tk is available there.
I downloaded the 5.12.3 installer to upgrade my 5.12.1 installation. After installing 5.12.3, my previously installed cpan modules are gone. Is this expected behavior? Should I be backing up my library before upgrading to prevent this?
I would claim that this should not be expected behavior.
The site directories are not part of the standard distribution and should not be touched by the distribution. Heck, it's even why the site directories even exist. Otherwise, why not simply download all of the modules to the same directory? Why make a distinction between the standard Perl modules and the modules you download from CPAN?
I too found this out the hard way when my personal modules -- modules that are not part of CPAN -- were blown away by my upgrade of Strawberry Perl. ActivePerl does it right -- not only not touching the site directory, but also adds in the Perl version to the standard module directory and the site directory.
It is expected behavior. Next time you can use "autobundle" feature of CPAN client, it will create list/bundle of modules to reinstall using CPAN client in new version.
I'm attempting to import code written in linux into eclipse's perl plugin 'epic', and have installed activestate perl in windows. Most of the modules have an activestate equivalent, but some of them I can't find in ppm. Does anyone know how I can get the following modules so that the code can compile?
File::Finder
Spreadsheet::WriteExcel::Utility
Sybase::CTlib
Sybase::DBlib
Sybase::Xfer
Template
Template::Constants
DBD::Sybase
File::Rsync
PerlIO/gzip
The best option is probably to remove Active Perl and replace it with Strawberry Perl. Because the Strawberry Perl installation includes a compiler, you are able to install most CPAN modules using the standard CPAN shell.
Trouchelle to the rescue!
http://trouchelle.com/perl/ppmrepview.pl?l=Template-Toolkit&v=10
The other modules cannot be built because of test failures or missing libraries.
i downloaded the File:finder module from cpan and was able to install successfully in the windows.
Only difference is we need to use nmake instead of make.
You can download perl modules from https://metacpan.org/ and then compile the same in windows.