On 05/11/2012 03:01, hong zeng wrote:
When I run the send_email example on the website, I got some warning
like this...I am really a beginner so I don't know where to find the
answer so I post here. Thank you guys.
ece% perl ./perl_test/send_email.pl
Can't locate Email/MIME.pm in @INC (@INC contains:
/afs/bp.ncsu.edu/contrib/perl561/lib/5.6.1/linux...
I’m not a Linux user, but looks to me as if you are using the
University’s installation of Perl and this is 5 versions and many years
out of date. Before you start anything, I would suggest you install the
latest version of Perl <http://www.perl.org/> on your own machine at the
default location /usr/local. Then you will have control and will be
able to install the modules you need, using CPAN.
This is rather a daunting task for someone who has not done it before,
and I would strongly advise you to get one of your sysadmins to walk you
through it. It is in fact much easier than it seems, but you will not
know that! I suggest you read
<http://learn.perl.org/installing/unix_linux.html>, but there may well
be better introductions that others on the list can recommend.
The proper way to install modules that are not in the standard
installation is to use CPAN, which is a part of the Perl installation.
It is no good to do as one or two replies have suggested. When you
install a module it will almost always require the prior installation of
other modules in their proper places in the libraries. CPAN knows all
this and will perform the installation of all the necessary
prerequisites for your module.
It is always very frustrating at the beginning when you set out to learn
a new language, because you have to learn and do very basic things that
most people take for granted. In the case of Perl, a solid installation
in the default location and a knowledge of how to use CPAN is a
prerequisite to smooth progress.
When everything is installed, your scripts will need to have the shebang
#!/usr/local/bin/perl
JD
--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/