FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Fedora User

 
 
LinkBack Thread Tools
 
Old 06-25-2008, 07:52 PM
"Wei, Alice J."
 
Default Install Perl on Fedora

Hi, Fedora Users:

I am just starting out to use Fedora and learned about installations with the yum function.
I have installed Perl 5.10.0-26, and the message shows that it had been installed:

Updated: perl.i386 4:5.10.0-26.fc9 perl-ExtUtils-MakeMaker.i386 0:6.36-26.fc9 perl-ExtUtils-ParseXS.i386 1:2.18-26.fc9 perl-Module-Pluggable.i386 1:3.60-26.fc9 perl-Pod-Escapes.i386 1:1.04-26.fc9 perl-Pod-Simple.i386 1:3.05-26.fc9 perl-Test-Harness.i386 0:2.64-26.fc9 perl-devel.i386 4:5.10.0-26.fc9 perl-libs.i386 4:5.10.0-26.fc9 perl-version.i386 3:0.74-26.fc9
Complete!

However, when I tried to execute a basic hello script in Perl, it tells me
bash: ./total.pl: /usr/local/bin/perl: bad interpreter: No such file or directory

It is true that I don't see Perl in this directory, but is it necessary that I have to move my Perl installation?

Thanks in advance.

Alice
================================================== ====
Alice Wei
MIS 2009
School of Library and Information Science
Indiana University Bloomington
ajwei@indiana.edu

--
fedora-list mailing list
fedora-list@redhat.com
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
 
Old 06-25-2008, 07:59 PM
Geoffrey Leach
 
Default Install Perl on Fedora

On 06/25/2008 12:52:22 PM, Wei, Alice J. wrote:
> Hi, Fedora Users:
>
> I am just starting out to use Fedora and learned about
> installations
> with the yum function.
> I have installed Perl 5.10.0-26, and the message shows that it had
> been installed:
>
> Updated: perl.i386 4:5.10.0-26.fc9 perl-ExtUtils-MakeMaker.i386
> 0:6.36-26.fc9 perl-ExtUtils-ParseXS.i386 1:2.18-26.fc9
> perl-Module-Pluggable.i386 1:3.60-26.fc9 perl-Pod-Escapes.i386
> 1:1.04-26.fc9 perl-Pod-Simple.i386 1:3.05-26.fc9
> perl-Test-Harness.i386 0:2.64-26.fc9 perl-devel.i386 4:5.10.0-26.fc9
> perl-libs.i386 4:5.10.0-26.fc9 perl-version.i386 3:0.74-26.fc9
> Complete!
>
> However, when I tried to execute a basic hello script in Perl, it
> tells me
> bash: ./total.pl: /usr/local/bin/perl: bad interpreter: No such file
> or directory
>
> It is true that I don't see Perl in this directory, but is it
> necessary that I have to move my Perl installation?

What does "% locate perl" say? Put that after #! in the first line of
total.pl. Alternatively, try "% perl total.pl"

--
fedora-list mailing list
fedora-list@redhat.com
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
 
Old 06-25-2008, 08:02 PM
"Alan J. Gagne"
 
Default Install Perl on Fedora

Wei, Alice J. wrote:


However, when I tried to execute a basic hello script in Perl, it tells me
bash: ./total.pl: /usr/local/bin/perl: bad interpreter: No such file or directory



If you execute [#which perl ] it should return /usr/bin/perl .
Do you have a line at the top of your total.pl script like this
(#!/usr/local/bin/perl).

It should read /usr/bin/perl.

Alan

--
fedora-list mailing list
fedora-list@redhat.com
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
 
Old 06-25-2008, 08:03 PM
Mike Bird
 
Default Install Perl on Fedora

On Wed June 25 2008 12:52:22 Wei, Alice J. wrote:
> However, when I tried to execute a basic hello script in Perl, it tells me
> bash: ./total.pl: /usr/local/bin/perl: bad interpreter: No such file or
> directory

Change the first line of the script to point to the correct Perl
location. You probably want "#!/usr/bin/perl" without the quotes.

--Mike Bird

--
fedora-list mailing list
fedora-list@redhat.com
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
 
Old 06-25-2008, 08:03 PM
Todd Zullinger
 
Default Install Perl on Fedora

Wei, Alice J. wrote:
> I am just starting out to use Fedora and learned about
> installations with the yum function.
[...]
> However, when I tried to execute a basic hello script in Perl, it
> tells me
> bash: ./total.pl: /usr/local/bin/perl: bad interpreter: No such file or directory
>
> It is true that I don't see Perl in this directory, but is it
> necessary that I have to move my Perl installation?

It would be better to adjust your script to point to /usr/bin/perl.
If you need the script to run on various systems where perl might be
in /usr/bin or /usr/local/bin or somewhere else in the path, you could
also use /usr/bin/env perl or (I think) just perl.

All of this is on the first line of the perl script you're trying to
run, aka the shellbang, shebang, hashbang, etc. It needs to start
with #!. So one of these should work:

#!/usr/bin/perl
#!/usr/bin/env perl
#!perl

--
Todd OpenPGP -> KeyID: 0xBEAF0CE3 | URL: www.pobox.com/~tmz/pgp
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~
Going to hell when I die would just be redundant.

--
fedora-list mailing list
fedora-list@redhat.com
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
 
Old 06-25-2008, 08:23 PM
Max Pyziur
 
Default Install Perl on Fedora

On Wed, 25 Jun 2008, Wei, Alice J. wrote:


Hi, Fedora Users:

I am just starting out to use Fedora and learned about installations with the yum function.
I have installed Perl 5.10.0-26, and the message shows that it had been installed:

Updated: perl.i386 4:5.10.0-26.fc9 perl-ExtUtils-MakeMaker.i386 0:6.36-26.fc9 perl-ExtUtils-ParseXS.i386 1:2.18-26.fc9 perl-Module-Pluggable.i386 1:3.60-26.fc9 perl-Pod-Escapes.i386 1:1.04-26.fc9 perl-Pod-Simple.i386 1:3.05-26.fc9 perl-Test-Harness.i386 0:2.64-26.fc9 perl-devel.i386 4:5.10.0-26.fc9 perl-libs.i386 4:5.10.0-26.fc9 perl-version.i386 3:0.74-26.fc9
Complete!

However, when I tried to execute a basic hello script in Perl, it tells me
bash: ./total.pl: /usr/local/bin/perl: bad interpreter: No such file or directory


Your bang line doesn't need "local";
#!/usr/bin/perl
should suffice.

#!/usr/bin/perl -w
is helpful for debugging.


Logged in as root, you could always create a symlink, but that could cause
headaches later if you stick to #!/usr/local/bin/perl


ln -s /usr/bin/perl /usr/local/bin/perl

Max Pyziur
pyz@brama.com



It is true that I don't see Perl in this directory, but is it necessary that I have to move my Perl installation?

Thanks in advance.

Alice
================================================== ====
Alice Wei
MIS 2009
School of Library and Information Science
Indiana University Bloomington
ajwei@indiana.edu

--
fedora-list mailing list
fedora-list@redhat.com
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list



--
fedora-list mailing list
fedora-list@redhat.com
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
 
Old 06-25-2008, 08:32 PM
"Kevin J. Cummings"
 
Default Install Perl on Fedora

Wei, Alice J. wrote:

Hi, Fedora Users:

I am just starting out to use Fedora and learned about installations with the yum function.
I have installed Perl 5.10.0-26, and the message shows that it had been installed:

Updated: perl.i386 4:5.10.0-26.fc9 perl-ExtUtils-MakeMaker.i386 0:6.36-26.fc9 perl-ExtUtils-ParseXS.i386 1:2.18-26.fc9 perl-Module-Pluggable.i386 1:3.60-26.fc9 perl-Pod-Escapes.i386 1:1.04-26.fc9 perl-Pod-Simple.i386 1:3.05-26.fc9 perl-Test-Harness.i386 0:2.64-26.fc9 perl-devel.i386 4:5.10.0-26.fc9 perl-libs.i386 4:5.10.0-26.fc9 perl-version.i386 3:0.74-26.fc9
Complete!

However, when I tried to execute a basic hello script in Perl, it tells me
bash: ./total.pl: /usr/local/bin/perl: bad interpreter: No such file or directory

It is true that I don't see Perl in this directory, but is it necessary that I have to move my Perl installation?


No, just put a symlink in /usr/local/bin that points to the fedora perl
at /usr/bin/perl



Thanks in advance.


--
Kevin J. Cummings
kjchome@rcn.com
cummings@kjchome.homeip.net
cummings@kjc386.framingham.ma.us
Registered Linux User #1232 (http://counter.li.org)

--
fedora-list mailing list
fedora-list@redhat.com
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
 

Thread Tools




All times are GMT. The time now is 10:12 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org