[Chicago-talk] perl 5.10.1 linux Question

Steven Lembark lembark at wrkhors.com
Tue Oct 20 05:03:18 PDT 2009

On Mon, 19 Oct 2009 23:51:13 +0700
Joakim Lagerqvist <joakim.lagerqvist at gmail.com> wrote:

> 2009/10/19 Craig <fasteliteprogrammer at gmail.com>:
> > i mean all the tools that come with perl when you download the source.
> I would recommend that you keep the perl that comes with fedora so
> that you don't break dependencies when you install/updated with tools
> like yum.
> Instead you can compile and install a perl that you put in /usr/local
> (or something) that you can use for anything non-fedora. Additionally
> use local::lib and install modules in your home directory or
> somewhere.

They have worked for me. Some of your 5.10.0 code
may have problems due to differences in smart-match
handling in 5.10.1.

I'd leave the perl that came with your O/S alone: it
is part of the core distro. Just build a copy of your
own (trivial on today's hardware) with something like:

    perl -d -e -Dprefix=/opt/perl/5.10 -Duseshrplib -Doptimize='-O3 -march=barcelona -pipe';

To avoid version conflicts and test out new versions,
I put them in separate subdir's by version number. 
Upgrading the version after testing it requires

    cd /opt/perl;
    rm *;
    ln -fs <new version>/* .;

and /opt/perl/bin/, etc, all point to the version 
I want to use. Downgrading is just a matter of a 
cd, rm, and symlinking an older version.

If you get sick of typing /opt/perl/bin/perl (or
don't want your $PATH to get a mile long) then 

    cd /opt/bin/;
    ln -fs ../perl/bin/* .;

and put /opt/bin/ onto your path. The version-
speicfic links make upgrades and downgrades 
invisible to the code. Anything that requires
a specific version can use


The version directory also avoids issues with 
overwriting working library versiosn with new
ones during testing.

You can also use:

    #!/bin/env perl

to run perl from your path, which allows testing 
the newer versions by updating your path; the 
default path can be just "/opt/bin:..." to get
the current version from /opt/perl.


Steven Lembark                                          85-09 90th St.
Workhorse Computing                               Woodhaven, NY, 11421
lembark at wrkhors.com                                    +1 888 359 3508

More information about the Chicago-talk mailing list