Operating System - HP-UX
1758650 Members
1814 Online
108874 Solutions
New Discussion юеВ

perl 5.6.1 not installed - why?

 
SOLVED
Go to solution
Gerard McNeill
Advisor

perl 5.6.1 not installed - why?

Hi,

I have installed perl version 5.6.1 via swinstall, there was no problems and i thought it was installed correctly, however when i perform a perl v - get the perl version 4.0 appearing.

Any ideas why this may be happening??
Gerard
11 REPLIES 11
John Poff
Honored Contributor

Re: perl 5.6.1 not installed - why?

Hi,

Do you have your path set correctly? It sounds like you are picking up the old Perl that comes in /usr/contrib/bin/perl. When I installed Perl 5.6.1 from the depot package, it put it into /opt/perl5/bin. I made a symlink for /usr/bin/perl to point to /opt/perl5/bin/perl.

JP
Gerard McNeill
Advisor

Re: perl 5.6.1 not installed - why?

John,

Tried the following but still no joy -


$ symlink() /usr/bin/perl /application/opt/perl/binperl5.6.1

$ perl -v

This is perl, version 4.0

$RCSfile: perl.c,v $$Revision: 4.0.1.8 $$Date: 1993/02/05 19:39:30 $
Patch level: 36

Copyright (c) 1989, 1990, 1991, Larry Wall

Perl may be copied only under the terms of either the Artistic License or the
GNU General Public License, which may be found in the Perl 4.0 source kit.
$ exit

Gerard
Jeff Schussele
Honored Contributor

Re: perl 5.6.1 not installed - why?

Hi Gerard,

Use this command
ln -s /usr/bin/perl /application/opt/perl/binperl5.6.1

Rgds,
Jeff
PERSEVERANCE -- Remember, whatever does not kill you only makes you stronger!
Rodney Hills
Honored Contributor

Re: perl 5.6.1 not installed - why?

As John said, did you do a "echo $PATH" and did you see if /usr/contrib/bin was in it.

You can also type "whence perl" under ksh and it will tell you which binary it will run.

HTH

-- Rod Hills
There be dragons...
Gerard McNeill
Advisor

Re: perl 5.6.1 not installed - why?

Hi

Still no joy. Here is what i am doing - any other ideas?

# echo $PATH
/usr/local/bin/gcc:/opt/binutils/bin:/opt/byacc/bin:/var/adm/sw/products/gcc:/us
r/local/bin:/var/adm/sw/products/byacc/pfiles:/usr/sbin:/usr/bin:/usr/ccs/bin:/u
sr/contrib/bin:/opt/nettladm/bin:/opt/fc/bin:/opt/fcms/bin:/opt/upgrade/bin:/opt
/pd/bin:/usr/bin/X11:/usr/contrib/bin/X11:/opt/resmon/bin:/usr/sbin/diag/contrib
:/opt/hparray/bin:/opt/ignite/bin:/sbin:/home/root

As you can see from above /usr/contrib/bin is there..

# ln -s /usr/bin/perl /application/opt/perl/bin/perl5.6.1
ln: /application/opt/perl/bin/perl5.6.1 exists
# perl -v

This is perl, version 4.0

$RCSfile: perl.c,v $$Revision: 4.0.1.8 $$Date: 1993/02/05 19:39:30 $
Patch level: 36

Copyright (c) 1989, 1990, 1991, Larry Wall

Perl may be copied only under the terms of either the Artistic License or the
GNU General Public License, which may be found in the Perl 4.0 source kit.

Still no luck?
Gerard
Rodney Hills
Honored Contributor

Re: perl 5.6.1 not installed - why?

What does the results of "whence" show?

-- Rod Hills
There be dragons...
Gerard McNeill
Advisor

Re: perl 5.6.1 not installed - why?

# whence perl
/usr/contrib/bin/perl
#
Gerard
Jeff Schussele
Honored Contributor
Solution

Re: perl 5.6.1 not installed - why?

Hi (again) Gerard,

Man, I'm a real idiot today - must have a dyslexic brain-thing going.
Had that backwards - NEEDS to be

ln -s /application/opt/perl/binperl5.6.1 /usr/bin/perl

Sorry,
Jeff
PERSEVERANCE -- Remember, whatever does not kill you only makes you stronger!
Rodney Hills
Honored Contributor

Re: perl 5.6.1 not installed - why?

I think your ln command is backwards.

ln -s /application/opt/perl/bin/perl5.6.1 /usr/bin/perl

Will make /usr/bin/perl run perl5.6.1

But verify you haven't wiped out perl5.6.1, enter-
/application/opt/perl/bin/perl5.6.1 -v
and see what version. You may have overwritten it and put a symbolic link in its place. In which case you might have to swinstall again.

HTH

-- Rod Hills
There be dragons...