linux perl5.16.3 install / run script error

Posted by grumpy13 on 2014-01-25 17:37

or more to the point, won't run script.
error message;
localhost gary # /home/gary/Perl/ run
bash: /home/gary/Perl/ /opt/ActivePerl*/bin/perl^M: bad interpreter: No such file or directory
localhost gary #

i did the; chmod +x /home/gary/Perl/

The shabang line to; /opt/ActivePerl-5.16/bin/perl
(thats where the perl install lives)

tried to run the bash shell over it to see it;
'perl /home/gary/Perl/'

Recoamimdations from google;

So whats up, how do i run perl script in linux - mint - mate

lylcanbys | Tue, 2014-01-28 05:06

Upload your script in Text mode if you use ftp


Replace the faulty Windows lineendings ^M with

perl -pi.orig -e 's#\r\n#\n#g'

ActiveState Staff
Tue, 2014-01-28 09:46

Don't unpack the zip file by using the Linux Archive Manager. Use gtar instead as described.

Make sure you have $PATH set correctly after you install.