Here is all you need to know to copy the modules from vendor_perl. It comes from a doco email and deals specifically with the redHat problems of vendor_perl.
Note don't copy binaries from 5.6.x vendor_perl to 5.8.x as it won't work. You can copy vanilla perl modules with impunity, but the binary ones in i386/i686 can only get copied if the are for 5.6.x or 5.8.x already.
I have configured, make(d) and installed 5.6.2 into default /usr/local
+/lib/perl5 location along side 5.8.3
This is mostly for common benefit to document the changes/process aka
+how to fix RedHats eclectic install!
To get all the modules we have installed into 5.6.2 @INC I looked at w
+here 5.6.1 is looking by erroring it out on a non existant module
[root@devel3 perl5]# perl -MFOO -e 1
Can't locate FOO.pm in @INC (@INC contains: /usr/lib/perl5/5.6.1/i386-
+linux /usr/lib/perl5/5.6.1 /usr/lib/perl5/site_perl/5.6.1/i386-linux
+/usr/lib/perl5/site_perl/5.6.1 /usr/lib/perl5/site_perl/5.6.0 /usr/li
+b/perl5/site_perl /usr/lib/perl5/vendor_perl/5.6.1/i386-linux /usr/li
+b/perl5/vendor_perl/5.6.1 /usr/lib/perl5/vendor_perl .).
BEGIN failed--compilation aborted.
[root@devel3 perl5]# perl5.6.2 -MFOO -e 1
Can't locate FOO.pm in @INC (@INC contains: /usr/local/lib/perl5/5.6.2
+/i686-linux /usr/local/lib/perl5/5.6.2 /usr/local/lib/perl5/site_perl
+/5.6.2/i686-linux /usr/local/lib/perl5/site_perl/5.6.2 /usr/local/lib
+/perl5/site_perl .).
BEGIN failed--compilation aborted.
[root@devel3 perl5]#
The core modules for perl are in perl5/5.x.x Note different roots at /
+usr/lib/perl5 for 5.6.1 and /usr/local/lib/perl5 for 5.6.2 The latter
+ location is the default but as usual redhat just had to put it somew
+here else!
The perl5/site_perl/5.x.x dirs contain all the user insalled non core
+modules. To complicate matters with 5.6.1 the binaries went into i386
+-linux but with the new installs this dir is called i686-linux.
To get all our installed modules into the right location I have done:
[root@devel3 5.6.2]# ls /usr/lib/perl5/site_perl/5.6.0
Net SGMLS SGMLS.pm skel.pl
OK no binaries for 5.6.0 to worry about renaming from i386....
[root@devel3 5.6.2]# cp -R /usr/lib/perl5/site_perl/5.6.0/* /usr/local
+/lib/perl5/site_perl/5.6.2/
[root@devel3 5.6.2]# cp -R /usr/lib/perl5/site_perl/5.6.1/* /usr/local
+/lib/perl5/site_perl/5.6.2/
[root@devel3 5.6.2]# mv /usr/local/lib/perl5/site_perl/5.6.2/i386-linu
+x /usr/local/lib/perl5/site_perl/5.6.2/i686-linux
There is also some stuff in vendor_perl GOK. I just took the binaries.
+...
cp -R /usr/lib/perl5/vendor_perl/5.6.1/i386-linux/* /usr/local/lib/per
+l5/5.6.2/i686-linux/
[root@devel3 5.6.2]# pwd
/usr/local/lib/perl5/site_perl/5.6.2
[root@devel3 5.6.2]# ls
Algorithm Crypt File i686-linux lwptut.pod SGMLS.pm WWW
Apache Data Foomatic if.pm Mail skel.pl YAM
+L
Benchmark Devel GD LWP MIME Test YAM
+L.pm
Bundle Digest HTML lwpcook.pod Net URI YAM
+L.pod
Compress Digest.pm HTTP LWP.pm SGMLS URI.pm
[root@devel3 5.6.2]# ls /usr/lib/perl5/site_perl/5.6.0
Net SGMLS SGMLS.pm skel.pl
[root@devel3 5.6.2]#
Finally I did:
[root@devel3 5.6.2]cd /usr/bin
[root@devel3 bin]# ls perl*
perl perl5.6.1 perl5.6.2 perl5.8.3 perlbug perlcc perldoc
[root@devel3 bin]# rm perl
rm: remove `perl'? y
[root@devel3 bin]# ln -s perl5.6.1 perl
[root@devel3 bin]# perl -v
This is perl, v5.6.1 built for i386-linux
Copyright 1987-2001, Larry Wall
[root@devel3 bin]# rm perl
rm: remove `perl'? y
[root@devel3 bin]# ln -s perl5.6.2 perl
[root@devel3 bin]# perl -v
This is perl, v5.6.2 built for i686-linux
Copyright 1987-2003, Larry Wall
So we are now pointed at 5.6.2 when you do /usr/bin/perl. We can chang
+e to 5.6.1 or 5.8.3 just by changing the symlink. If you want 5.8.3 j
+ust ask for it #!/usr/bin/perl5.8.3
If seemed to work OK.....
[root@devel3 bin]# perl -MDBI -e 1;
[root@devel3 bin]# perl -MSmartSurf::Bayes::BayesXS -e 1;
[root@devel3 bin]#
Then I did this to run our test suite
/t/run
Which mostly ran but complained about the odd module being missing. Th
+ese were in per5/vendor_per/5.6.1 but there were also a whole lot of
+out of date modules in there so I just reinstalled the latest version
+ of missing things like HTML::Tagset by hand rather than overwrite cu
+rrent modules with old versions.
Anyway the Redhat abortion of a default perl setup with 9 dirs in @INC
+ is now rationalised. All we need is the /usr/local/lib/perl5 tree an
+d we will have all modules we installed for 5.6.2 and 5.8.3
|