Installing modules on Active Perl 5.6 on Windows - perl

I am using ActivePerl 5.6.1 Build 635 (let's assume that I absolutely have to work with this version and cannot update to a newer one) on a Windows XP machine. The ppm version with this version of Perl is 2.2.0 and is not the same as the ppm for later versions (as mentioned here ). I am trying to accomplish a simple task : INSTALLING THE PERL MODULE "RPC::XML". Here is a list of things I have done :
1 : Tried installing using CPAN (one of many links as to how to do this is here) but the make commands won't run on my command line as I do not have nmake installed.
2 : Tried using ppm. However I get the following error despite using a direct internet connection.
**PPM> search "RPC::XML"
Error connecting to 'http://ppm.ActiveState.com/cgibin/PPM/ppmserver.pl?urn:/PPMServer'.**
Also I have read that some perl modules for versions 5.8 and above are not even compatible with version 5.6. The activeperl website doesn't even have a version for download for verison 5.6 (as can be seen here).
So my problem is simple.
All I want to do is install a perl module (RPC::XML say) on 5.6.1 using 2.2.0. Also let me know why ppm seems to be unable to connect when I am using a simple direct internet connection.
I am about 2 days old to perl. Ignore any noob statements I might have written, and correct me.

The nice folks at ActiveState give free access to their PPM repositories for folks using their 2 latest releases of perl. Access to their legacy repositories is available for a price.
As such your choices seem to be:
install nmake & use cpan (may also require a c compiler for some modules)
install a relatively modern copy of perl (i.e. free support)
shell out cash for an 'enterprise' subscription of ActivePerl and get your stuff via ppm. (Of course even the Activestate folks my not choose to support any software versions that old.)
do without any of the above, manually parse the make file & type in the commands yourself.

Related

Can I have the newest version of perl together with olde

I have on UNIX SunOS 5.9 Generic_122300-61 sun4u sparc SUNW,Sun-Fire-V240 perl v5.6.1, but I want to install the newest version.
Can I install the newest version and have it together with oldest but on different directories?
But my questions is :
now I have perl home on /bin/perl.
The newest perl version will be on different home directory? And also cpan and modules, are they going to be installed?
Since you are on Solaris, don't mess with the Perl that comes with the operating system. It's used by the OS itself, and if you change it things can get weird.
That said, you can absolutely install other Perl versions in parallel with it. If you're compiling manually, all you need to do is to give the flag -Dprefix=/some/nice/directory to the Configure script. Once it's compiled and installed, you only need to put /some/nice/directory/bin earlier in your PATH than /usr/bin.
If you want a system-wide installation of a newer Perl, I'd suggest picking the latest version (currently 5.20.0, but 5.20.1 is at RC2 so it should be out soon) and installing it in /usr/local. If you want a newer Perl for your own personal use, I'd strongly suggest making sure you have enough of an environment that Perl can be compiled, and then install and use perlbrew (http://perlbrew.pl/).

installing wxPerl on strawberry

I am trying to install wxperl on strawberry. I can't install Alien::wxWidgets. I tried everything I can think of. Usually I get an error like this one:
Creating library file: ..\..\src\stc\..\..\..\lib\gcc_dll\libwxmsw28u_stc.a
compilet.exp:fake:(.edata+0x3c): undefined reference to `boot_compilet'
compilet.exp:fake:(.edata+0x40): undefined reference to `boot_compilet'
I don't know what that means. I tried with wxWidgets v 2.8.12 and 2.9.3 and various options. I started with cpanm and later evoking perl Build.PL manually with all kinds of options.
I am on Windows 7 64 bit. I tried with 5.14.2 32bit and 64bit. I am pretty sure that my path has no other perl installation than the one I currently using.
Any ideas? Thanks!
Using strawberry-perl-5.16.3.1-32bit on Windows 7.
It seems that even though the build process crashes with the error message above, Alien::wxWidgets has, in fact, been successfully made, and is ready to install.
Got the same error message building Alien::wxWidgets from SVN trunk. I ran 'build test' and the tests passed so I ran 'build install'. Wx compiled successfully, all tests passed. Padre editor compiled successfully, all tests passed, and it works well.
It is also possible to install via PPM in Strawberry perl:
ppm set repository wxPerl http://www.wxperl.co.uk/repo29 (for WxWidgets-2.9.4)
ppm install Alien::wxWidgets (version 0.61)
Unfortunately, the latest version of Padre editor requires Alien::wxWidgets 0.62, so building Alien::wxWidgets from source is necessary to make Padre from CPAN.
Alternately, you can use the Citrus Perl distribution created by Mark Dootson. One caveat, the version of Perl, 5.16.1, is not the latest, but it is more recent than DWIM Perl build of Strawberry Perl 5.14.2.1 RC.
I would recommend using the latest Strawberry Perl 5.16.3, or 5.14.4.1 for security reasons because it has a a fix for the rehashing flaw which could be used for denial of service attacks. Described here:
http://www.vuxml.org/freebsd/CVE-2013-1667.html
One idea is to install DWIM Perl, which is a Perl distribution which contains Strawberry preloaded with a whole lot of commonly used CPAN modules, and includes Alien::wxWidgets.

Activestate perl 5.14.2.1402 and Perlfect search 3.37 DB_File error on IIS 7

I am getting an error trying to install Perlfect search after I run setup.pl
The required DB_File module was not found on your system
I've tried following the instructions from the Perlfect search readme and also from How do I install Perl 5.8 and Perlfect on IIS 7.5? on Serverfault but can't get past the step of running the setup.pl.
If you take a look at the DB_File PPM page you'll see that DB_File has not been built for Windows, either 32- or 64-bit. If you look at one of the build logs you'll see that its because the build is disabled. An older log reveals that it's disabled because ActiveState knows that Berkeley DB is not available, so the build will fail.
So, you'll need to either find a way to built it yourself, or alternatively see if you can get Strawberry Perl to work. According the the Win32 Perl Wiki entry Install DB File on Strawberry Perl that is fairly easy.

How do I install Devel::Cover on ActivePerl 5.8.7?

cpan fails with this weird error as follows
Error: Unable to locate installed Perl libraries or Perl source code.
It is recommended that you install perl in a standard location before
building extensions. Some precompiled versions of perl do not contain
these header files, so you cannot build extensions. In such a case,
please build and install your perl from a fresh perl distribution. It
usually solves this kind of problem.
(You get this message, because MakeMaker could not find "D:\fbl_esc_bcd_tb\tools\perl\lib\CORE\perl.h")
Running make test
Make had some problems, maybe interrupted? Won't test
Running make install
Make had some problems, maybe interrupted? Won't install
Problem is I can't install new active perl versions in this environment and the tool I want to coverage on does not run outside this environment.
Short answer: The ActiveState PPM repository has a precompiled version of Devel::Cover you should be able to install.
Long answer: That's not a normal message from MakeMaker so I'm willing to guess its an ActiveState addition, but its probably true. The problem is exactly what the error message says; your distribution is missing some important files, specifically the C header files for Perl, so it cannot compile C code necessary for modules like Devel::Cover. This is often the result of an overzealous sysadmin or packager looking to save a few dozen K of disk space. You could probably take the header files from the 5.8.7 source, copy them into the CORE directory and it will probably work. It won't make anything worse.
I agree with Evan that, assuming this is a Windows machine, you should switch to Strawberry Perl which plays much better with the rest of the Perl community than ActivePerl.
Otherwise, ActiveState is a commercial company and they have paid Perl support. Give them a ring.
Active Perl does not use CPAN. If you want to use CPAN use Strawberry Perl. Active Perl uses binary distribution through its ppm system. There are a few third party repos for it if the official one doesn't have Devel::Cover -- though the official probably has Devel::Cover.
Most people these days are moving to Strawberry and away from AS. In my opinion, it is far more stable and CPAN-friendly, and surely less proprietary. Also, expect to be able to get stable versions of most everything - AS has been known to lag years in many occasions in the official repos. strawberry also comes with its own compiler and build environment so you can even get ::XS versions working with ease.

Why can't I find Perl modules after upgrading to Intrepid Ibex Ubuntu?

I upgraded to Ubuntu Intrepid Ibex yesterday and suddenly some of the Perl modules that I installed (on the Hardy Heron) have all gone missing!
I get the usual "Can't locate module in #INC" error. Has any of the CPAN repositories changed or something for Intrepid? Google doesn't help at all.
Thanks in advance.
The standard solution is to generate an "autobundle" with CPAN.pm before upgrading Perl. A search for autobundle yields links to a handful of existing SO questions discussing Perl module management and several that look like they should provide more information. The CPAN.pm manual touches on autobundle, but doesn't include much detail.
Since you've already upgraded Perl, one solution for installing your modules would be to generate an autobundle file and use the entries in the generated file as a guide to write a custom autobundle file with entries for your modules (only). The autobundle file format is just POD, so this should be easy to do.
In the future you should probably make it a habit to generate an autobundle before upgrading Perl. This is not a perfect solution, the autobundle will include entries for core modules that will have to be removed before actually building from it, but at least you'll have a snapshot of installed Perl modules so that you can get your Perl install fixed up after an upgrade.
Your Perl installation has changed from version 5.8 to 5.10. Since many of the modules you want are in perl-version-specific directories, you may want to re-install using the CPAN tools (e.g. the cpan command).
But since you're using Ubuntu, please keep in mind that many many CPAN libraries are also distributed through the Ubuntu package manager, and the CPAN packages install into a different place than Ubuntu installs them (this is transparent to the user, since both are in the #INC paths).
I recommend using the Ubuntu packages when they're available, because they will be updated by the package manager (APT) when new ones are released on the central package servers. The name format is slightly different. Here are two ways to install the same package, from different sources:
$ cpan List::MoreUtils # installs latest from CPAN
$ sudo apt-get install liblist-moreutils-perl # installs latest from Ubuntu universe
the advantage of the latter is that it will be updated by sudo apt-get update.
Perl changed on Intrepid.
Before upgrading, you had Perl 5.8, now you have 5.10.
Probably /usr/lib/perl5/5.10.* is used instead of /usr/lib/perl5/5.8.8 since the Perl version has changed