Installation and Deployment
To compile Aluminium you need Qt (version 4.5 or newer). Compilation is done by running:
qmake && make
in the directory you extracted the source (note, that qmake may have a different name in your distribution (e.g. qmake-qt4)). This will produce a directory named bin, containing two executables (alrunc and alconst) and a directory (plugins).
alconst is the Aluminium application editor.
alrunc is used to execute the *.al files:
./alrunc --help
Aluminium Runner v0.4
Usage: alrunc [OPTIONS] [<input file>]
Options:
-p <plugin directory> - where to look for operation plug-ins
-t - print the amount of consumed time at the end
All operations are compiled as separate libraries, loadable at run time (placed in the plugins directory). By default, alrunc looks for them in the standard Qt plug-in directory (depends on your Qt installation. For example, in the distribution I use, it is /usr/lib/qt/plugins/almodules). To change this directory, you can use qt.conf, or the -p option.
-t option enables time debugging - <!-- served in ??? ms --> will be printed at the end of each generated document.
If input file is not specified, data is read from stdin.
If you are going to install Aluminium in an environment where Qt is not installed globally, you might want to read this.
Using With Apache
Perhaps the easiest way to set up Aluminium with Apache is to use the Action and AddHandler directives. In the global Apache configuration file, or a local .htaccess file, you should add these lines:
Action al-run /cgi-bin/alrun.sh AddHandler al-run .al
And the alrun.sh script could look like this:
#!/bin/sh # In case Qt isn't installed globally: #export set LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/path/to/qt/libs exec /path/to/alrunc -p /path/to/almodules $PATH_TRANSLATED
You might also want to make index.al to work like a directort index with DirectoryIndex directive:
DirectoryIndex index.al
Using With Lighttpd
To set up Aluminium with Lighttpd, first make sure mod_cgi module is enabled. Then add ".al" extension to the static-file.exclude-extensions variable, and
".al" => "/path/to/alrunc"
to the cgi.assign variable. You might also want to add "index.al" to the index-file.names variable.