I am in a precarious spot....
I run centos 4.0. I upgraded my mod_perl RPM to mod_perl 2.0.1. CGI.pm 3.10 (3.05 comes with centos 4.0) fixes some namespace issues with mod_perl vs mod_perl 2.0.1. I need to upgrade to it to 3.10. Yet that file belongs to the perl rpm that comes with centos.
What do people generally do in this type of situation?
Do I need to compile a new perl just to upgrade CGI.pm to a newer version? Can I package the new CGI and install it ? If I do CGI.pm will be owned by 2 packages (the one I package and perl).
Thoughts , ideas?
Steve
On Wed, Jun 29, 2005 at 05:21:10PM -0400, Nielsen, Steve wrote:
I am in a precarious spot....
I run centos 4.0. I upgraded my mod_perl RPM to mod_perl 2.0.1. CGI.pm 3.10 (3.05 comes with centos 4.0) fixes some namespace issues with mod_perl vs mod_perl 2.0.1. I need to upgrade to it to 3.10. Yet that file belongs to the perl rpm that comes with centos.
What do people generally do in this type of situation?
What I generally do is install the new perl module with CPAN and overwrite the one that came in the RPM. When you do this you need to make darn sure you remember it when upgrade time comes or you'll be very sad.
It occurs to me that you could create a fake rpm package for cgi.pm that depends on an explicit version of perl, so any upgrade to perl will fail due to that dependency.
I've attached a spec file that i think will do this (for perl version 5.8.5-12.1, which is what i had installed on my system).
To create an RPM with it, you'll need to create an empty tar.gz file fakecgipm-3.10.tar.gz and put it in /usr/src/redhat/SOURCES, put the spec in /usr/src/redhat/SPECS, then do rpmbuild -bb on the spec file.
Then install the resulting RPM.
Next time you upgrade perl you'll have to remove this RPM first, or build a new one that requires the new version of perl and install it with the new perl rpm, and then go back in with cpan and reinstall the module. Not a seamless upgrade but easier than rolling your own perl each time.
danno -- dan pritts - systems administrator - internet2 734/352-4953 office 734/834-7224 mobile
On 6/29/05 2:21 PM, Nielsen, Steve wrote:
I am in a precarious spot....
I run centos 4.0. I upgraded my mod_perl RPM to mod_perl 2.0.1. CGI.pm 3.10 (3.05 comes with centos 4.0) fixes some namespace issues with mod_perl vs mod_perl 2.0.1. I need to upgrade to it to 3.10. Yet that file belongs to the perl rpm that comes with centos.
What do people generally do in this type of situation?
For Perl, I just do a complete build (hopefully scripted!) into /usr/local and manage it with CPAN. There are some packages, like RT, that require so many additional modules that it's just easier to maintain a local perl than it is to work with the system-installed version. So standard scripts can still reference /usr/bin/perl, but scripts with extensive local dependencies use /usr/local/bin/perl.