Perl Application Development and Distribution Platform

With the constant improvement of Strawberry Perl, the recent release of the first Portable Strawberry and development on Padre, the Perl IDE I was thinking a bit on how to further extend these projects.

I though we should turn all this work into a platform for desktop application development and distribution.

There are several packages out there that allow you to develop a web application using MySQL, PHP and Apache on Windows (e.g. Devside) and even packages that you can use to host your web application (e.g. WAMP Server) but there is not so much for the desktop applications. I found Dabodev which is a Pyhton based framework that might be similar to what I'd like to have. I have not found one for Perl yet.

I'd like to have an easily installable package initially for Windows but later on maybe for Linux, Unix and Mac as well that can be used to both develop desktop applications and to easily distribute them. We already have CPAN, a nice distribution framework for modules but there are a few problems.

  • You alway get the latest version of every module that were not yet tested.
  • Two applications installed on the same system might require different versions of the same module.

If all the extra modules were installed in some application specific directory that would solve the second problem but you still get the latest of all the modules. If the application and all the extra modules are distributed in a PAR package the developer has almost full control over which version of the modules will be used. I write almost as there won't be control over the modules NOT in the par package.

So the technical requirements:

Install a baseline Perl that already includes lots of nice modules and a distribution framework. Especially install the most important modules that require compilation or things not on CPAN.

Strawberry Perl already includes PAR. Chocolate Perl will include wxPerl as well and maybe other GUI frameworks.

We need a way to distribute and install applications packaged as par archives. PAUSE/CPAN can already be used to distribute these packages. AFAIK neither CPAN nor CPANPLUS has any knowledge about such packages so we might need to either change those or provide a separate tool that will only install par packages.

As I discussed with Steffen Mueller, there is already a pair of modules: PAR::Repository and PAR::Repository::Client that can provide an alternative way for distribution and installation of PAR packages.

IMHO on this platform end-users should never install individual CPAN modules and even developers should install them in an application specific directory. That would avoid any unwanted upgrade of a prerequisite module. Developers might need several configurations of CPAN.pm to be used by each application they are working on.

The application installer tool should know more about the applications than CPAN.pm currently does. Somewhere there should be a 3 dimensional matrix of (Platform version X Application version X OS version ) where Platform version will be something like Strawberry Perl 5.10.0.3. At the beginning the OS version is always MS Windows but I hope this Platform can be extended to other operating systems as well.

The information in the 3D matrix is probably best provided by the application developer. The installation tool (similar to GUI version of ppm ?) should be able to help the user select which versions of the application are approved to his/her OS and current platform and install that version of the application.

Let's have an example:

  • I want to distribute an application that uses Module::Widget 1.12.
  • I tested my application on Chocolate Perl 5.10.0.27
  • As that version of Chocolate Perl already include Module::Widget 1.12 I don't include it in my PAR distribution
  • If a user tries to install my application on an older version of Chocolate Perl, that did not yet include Module::Widget 1.12, the tool will tell so and won't try to install the module

Later I would include Parrot in this framework and gradually allow other languages running over Parrot.

Comments

Steffen Mueller