talexb has asked for the wisdom of the Perl Monks concerning the following question:

The road to hell is paved with good intentions

It's all my fault -- I couldn't stand administering one more Windows 98 box. So I installed Mandrake 10 Linux on my older step-son's PC. Of course, he wanted to be able to run xChat so he could chat with his friends, so I installed that too.

Time passed. The system worked fine, he was able to slag Windows (something I didn't exactly discourage) and it ran fine on an oldish piece of hardware.

My step-son discovers Perl -- and it's not my fault

Chatting with his friend recently, his friend urged him to try out a Perl script that he'd picked up and fiddled with, to be used as a plug-in to xChat. Matt didn't have the plug-in, but his friend directed him to where he could pick it up, so I got it for him and tried installing it for him.

Someone tries to be clever

No go .. it required Perl 5.8.7, and the system was intalled with Mandrake 10.0, which had Perl 5.8.3. So I found a Mandrake RPM for Perl 5.8.7 but got an error installing it. So then I thoguht, what the heck, I'll download the source and build perl from source. How cool is that?

Building Perl, of course, is not a short process. It asks all kinds of questions, most of which I skipped, but two questions I did answer in a non-standard way -- it asked if I wanted to install 5.8.7 as a a separate Perl or the standard Perl (which it didn't recommend). I said, of course, make it the standard perl. it also asked if I wanted to make libperl.so (it didn't recommend it) and I said yes, because xChat wanted that file to install.

So, off it went, configuring, compiling, testing, installing, until about an hour later it was finished. Yay! Well, it was late, so I put off installing the rest of the stuff that xChat needed .. Perl was now 5.8.7, all was well with the world. Right?

No good deed goes unpunished

The next day, Matt went ahead with some homework, and had computer problems. He wrote me at work that he needed help, and so far Mr. Engineering Degree has been able to fake his way through high school algebra, trigonometry and physics no problem, so this should be a non-brainer. Right? Well, this challenge was a little different. Open Office wouldn't run on his system. Oh. That's not good.

Well, after a bit of dickering around, it turned out that Open Office was trying to load MDK::Common (?!?), and wasn't having any luck, because the 5.8.7 Perl didn't have anything installed with that name. No problem, I thought, and hustled off to RPMFind.net, downloaded the necessary and installed it. Or tried to -- rpm insisted that the library was already installed.

Of course it was -- on the 5.8.3 tree which I told the installation process to dump. Oops. So I tried forcing it (of course), and Open Office still wouldn't launch -- same problem.

I tried asking for help on this problem last night, and tye was most gracious with a couple of suggestions, but I am without success tonight, and I've been sharing my system with Matt since his isn't able to run Open Office.

The more I learn, the less I know

So. this brings up a few questions .. how could I have retained the 5.8.3 libraries for my 5.8.7 installation? tye suggested the Autobundle command from the CPAN shell -- does that play well with modules installed via rpm?

If I had installed 5.8.7 as a separated Perl, and left 5.8.3 alone, I still would have had the libperl.so (5.8.7) built somewhere under /usr/lib -- and I imagine the libperl.so link would still have pointed to libperl.so.5.8.3, so I could have use the 5.8.7 library without breaking my originall installation. is this what most folks do?

The slippery slope?

So, I'm at the point where I think I have to bite the bullet and reinstall Open Office -- unless someone can make some useful suggestions. Thanks in advance (no pressure -- it's just my rep as a Nerd Step-Dad that's at stake).

Alex / talexb / Toronto

"Groklaw is the open-source mentality applied to legal research" ~ Linus Torvalds

Replies are listed 'Best First'.
Re: Building 5.8.7 broke Open Office
by chromatic (Archbishop) on Oct 20, 2005 at 02:47 UTC

    Replacing a vendor-supplied Perl with one you compiled yourself often breaks things. I think everyone learns this the hard way -- I certainly did.

    If MDK::Common doesn't contain any binary components, you can probably use cpio to extract the .pm files and install them by hand. That might work.

      Replacing by overwriting is dicey; putting it somewhere else entirely is less dangerous. Safer to build to a separate prefix (e.g. /usr/local) and put that location on the front of your PATH.

      If you do this you're also more in control of when you upgrade the Perl version you're running against (for example, someone else could be the sysadmin and they might install new rpms/dpkgs/yadda yadda but you'll still be running against the version you've tested and know works).

Re: Building 5.8.7 broke Open Office
by dragonchild (Archbishop) on Oct 20, 2005 at 03:03 UTC
    (This is not meant to be snarky.)

    I have always distrusted rpms and apt-get for precisely this reason. When I ran redhat, I never used the RPM system, preferring to always build from source, even if I took the standard install. The only pkg management system I've come to like is the BSD ports, because they build from source.


    My criteria for good software:
    1. Does it work?
    2. Can someone else come in, make a change, and be reasonably certain no bugs were introduced?

      I agree -- I've only used rpms for a little while -- it's some magic that I just don't get or trust, while building from source is solid.

      The problems arise when there are dependencies .. sure, I built Perl from source (it's not the first time) but it also affected the stability of this particular system. And it appears that I would have had that problem whether or not I could get the rpm to install correctly anyway. Oh well.

      And I didn't think your response was snarky. ;)

      Alex / talexb / Toronto

      "Groklaw is the open-source mentality applied to legal research" ~ Linus Torvalds

Re: Building 5.8.7 broke Open Office
by Zaxo (Archbishop) on Oct 20, 2005 at 20:13 UTC

    You could rebuild 5.8.7 with the path to 5.8.3 modules in @INC. The two should be binary compatible. That will work if your new perl is compiled with the same configuration regarding threads and numeric types, and perhaps a few other things. I don't know if building the dll perl makes a difference for that.

    After Compline,
    Zaxo