How to compile Perl itself from source code

How to compile Perl itself from source code. First, fetch the Perl source code with "git clone".

git clone http://perl5.git.perl.org/perl.git

This is the latest branch of the current development version.

Then execute the following command listed in the README.

./Configure -des -Dprefix = $HOME/localperl

In the release version, this command will generate a Makefile, but in the development version it will fail, so execute the following command.

./Configure -des -Dusedevel -Dprefix = $HOME/localperl

Next is compilation. Execute the make command.

make

Next is the test.

make test

Finally installed. It will be installed in "$HOME/localperl".

make install

I've been touching the Perl source code a bit lately, but running make and make test after making changes is a bit unrealistic. This does everything, including testing the module.

So there is a way to compile a minimal amount of Perl or run a minimal amount of testing.

You can compile a small Perl called miniperl with the following command:

make miniperl

You can run a small test with the following command:

make minitest

Related Informatrion