7.4 The makelsr.pl script

As you might have guessed already, makelsr.pl is a Perl script. Obviously, you need Perl to execute it, which you should now install in case it isn’t already available on your system.

There is a dependency on the Pandoc program, which the script uses to convert LSR’s snippet documentation strings (which are formatted in HTML) to Texinfo. This must be installed, too.

Furthermore, makelsr.pl needs a few additional modules that are not Perl core modules (tested with Perl version 5.36):

Either install missing modules with your package manager (if available) or use the cpanm command.5

A typical call might me

cpanm --sudo Parallel::ForkManager

to download, compile, and install module ‘Parallel::ForkManager’.6

Finally, it needs to find the convert-ly script from the current LilyPond development build.

By default, executing makelsr.pl performs the following actions.

This flow of actions can be adjusted; say ‘scripts/auxiliar/makelsr.pl --help’ to get a detailed description of the provided command-line options and used environment variables.


Footnotes

(5)

Most Perl distributions have this command included; if not, try to install a package named ‘cpanminus’ or having ‘cpanminus’ in its name.

(6)

Note that the program cpanm might be called differently; it sometimes has the Perl version appended to its name, for example cpanm-5.34.

The --sudo option makes the modules install into a system directory, for example /usr/lib/perl5/site_perl/... – you need the supernotation password for this. If you don’t want to do that for whatever reason, just omit --sudo and follow the instructions shown in cpanm’s error message to install Perl modules locally (i.e., without sudo rights).

As of this writing (August 2022) there is a small buglet in a test of the ‘Pandoc’ module that makes it necessary to add option --notest for installing this module in case you have to use cpanm.


LilyPond Contributor’s Guide v2.25.21 (development-branch).