Skip to content
This repository was archived by the owner on Sep 3, 2019. It is now read-only.

How to upgrade Perl

Johannes Schindelin edited this page Mar 29, 2014 · 3 revisions

First of all, you need a development environment. Download and install the one-stop msysGit development environment installer. This will install the development environment and build an up-to-date Git version in it. You definitely want to install this development environment into a directory whose path does not have spaces in it. For example, C:\Program Files (x86)\msysGit is not a good place while C:\msysGit is.

To be able to open the development environment quickly again, you might want to install a desktop icon using the method suggested in the default message of the command-line window which was kept open at the end of the installation procedure: /share/msysGit/add-shortcut.tcl desktop.

Second, you need to switch to the 'MSys' development environment. By default, msysGit is set up to compile MinGW programs, i.e. plain Windows programs that do not use any POSIX features. In contrast, the Perl-Subversion modules require POSIX features that are supported by the POSIX emulation layer MSys (see also What is this "MSys" thing in "MSysGit"?). To switch to the 'MSys' development environment, close all msysGit windows, install Git for Windows, start a Git Bash and switch to the msys branch: cd /c/msysGit/ && git fetch && git checkout -t origin/msys.

To build the current Perl, all you have to do is to call /src/perl/release.sh.

To upgrade Perl, that file -- /src/perl/release.sh -- has to be modified. Unfortunately, it is usually not enough to update the version number and MD5 checksum. Typically, the build will fail after doing that, which means that patches are needed. The patches required for the current Perl version are located in /src/perl/patches/ and will be applied automatically by the release.sh script.

The process is now to switch the directory to /src/perl/perl-<VERSION>/ (which is now a Git repository in its own right) and patch the sources until make passes. Then, those changes need to be committed and to be exported to /src/perl/patches/ using the command git format-patch -o /src/perl/patches/ -<NUMBER> where <NUMBER> is the number of commits on top of the initial one.

Clone this wiki locally