Note:
My current and future development is concentrating on a stand alone distribution of Perl modules, Perl and Raspberry Pi, for installation in the system Perl on Raspberry Pi.
I have supported a binary Perl distribution called Citrus Perl for some time. It provides wxPerl GUI tools along with pre-built modules to connect to common Open Source databases and is available for Windows, Linux on x86 / x86_64 and Mac OS X.
I have produced a binary version of Citrus Perl for Raspbian Wheezy to provide a similar environment for the Raspberry Pi and have released it for download and installation.
Before downloading and installing Citrus Perl you need to install a few prerequisites. The standard Raspbian images use the gcc compiler version 4.6.3 by default. Perl compilation fails for ARM processors as used in the Raspberry Pi using this compiler. The later release gcc 4.7 is required. We can install gcc 4.7 on the Raspberry Pi. It can co-exist happily with the standard gcc 4.6.3.
If you have not updated your package system recently, you should do so first.
sudo apt-get updateYou can then install compiler tools that will allow Citrus Perl to build modules as required from the CPAN.
sudo apt-get install make gcc-4.7 g++-4.7The final prerequisites are the database client libraries if you intend to use DBD::Pg or DBD::mysql -
sudo apt-get install libmysqlclient18 libpq5Citrus Perl installs from a tarball to a fixed location under /var/local. The installation path is /var/local/citrus so the tarball is simply the 'citrus' directory. You should download and extract Citrus Perl using 'sudo'.
cd /var/localsudo wget http://sourceforge.net/projects/ citrusperl/files/Raspberry%20Pi/ citrus-raspbian-20130201.tar.bz2sudo tar xjf citrus-raspbian-20130201.tar.bz2Installation is then complete. To use Citrus Perl you can run a script referencing the executable directly -
/var/local/citrus/bin/perl myscript.plOr you can put the necessary directories on your path within a session so that the Citrus Perl executable becomes the default for that session -
export PATH=/var/local/citrus/site/bin: /var/local/citrus/bin:$PATHperl myscript.plYou can also make your scripts executable and use the first script line to identify the required command -
#!/var/local/citrus/bin/perl -wFor users of wxPerl you can run the WX::Demo application using :
/var/local/citrus/site/bin/wxperl_demo.pl
or if you have exported the amended $PATH as above you can simply
wxperl_demo.pl
For information, if you wish to build Perl from source rather than use a binary distribution, my configure script is here.
Leave a comment