Install Perl on Ubuntu

Source: Internet
Author: User
Tags install perl perl script

As people become more passionate about programming efficiency, scripting languages are popular, including Perl. Here we don't delve into Perl's history, nor do we dispute the merits of Perl and Python, and we'll see how to install Perl on Ubuntu, and the version I'm using is ubuntu11.10.

There's a lot of information about Perl and Activestateperldevkit ads on www.perl.com and www.cpan.org, but this tool is for a fee.

When we installed Perl on Ubuntu, we could write a Perl program that could run, including a DDoS version of the attack script, using any text editor such as Gedit, a fairly powerful text editor.

First get the installation file on www.cpan.org:

wget http://www.cpan.org/src/5.0/perl-5.14.2.tar.gz

(This version is recommended because the current version is the most stable and not old)

Unzip the file:

Tar-xzf perl-5.14.2.tar.gz

Enter directory:

CD perl-5.14.2

./configure–des-dprefix= $HOME/localperl

Make

Make Test

Installation:

Make install

Test process:

Open Gedit to enter the following Perl script:

#!/usr/bin/perl

print "hello,world!\n";

Save As HelloWorld (can not use suffix, also someone used. PLX suffix)

Enter the directory where the script file was just saved after opening terminal

Enter chmod a+x HelloWorld (Change the properties of the file to execute)

Enter Perlhelloworld or./helloworld execution

You will see terminal running results as:

hello,world!

Install Perl on Ubuntu

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.