elice (1) - Linux Manuals

elice: compiler for programs written in PureBasic


elice - compiler for programs written in PureBasic


elice [options...] [-o outfile] sourcefile...


elice is a compiler for programs written in the proprietary language PureBasic. It compiles such programs to C++ and then invokes g++ to generate an executable. Its interface is similar to that of g++.

Normal usage is to compile just one source file, which uses IncludeFile and XIncludeFile statements to incorporate whatever other source files are needed. Such include statements are resolved relative to the directory of the source file they are in. If there are multiple source files on the command line, they are compiled together to form one executable.

elice comes with a library of builtin procedures which will be included in the executable when they are needed. Depending on which builtin procedures are used, the resulting executable may be dynamically linked to other libraries such as libSDL.


Most options will be passed through to g++, so you can use -g -O2 and such as usual.
-o outfile
Use outfile as the name of the resulting executable. Without -o, the default is to use the name of the first source file without its extension (for example prog.pb becomes prog).
Save intermediate stages of compilation (C++ with suffix .cc, preprocessed C++ with suffix .ii, assembler code with suffix .s, object code with suffix .o) in the current directory.
Verbose mode. Print detailed information about the programs invoked during compilation.


The exit status is 0 if there were no errors. elice returns 1 if there was a parse error or an error in the command line. If the invocation of g++ fails, it returns the exit code from g++.


elice -g -O2 program.pb -o program


This program is a work in progress. It does not support the entire PureBasic language, and supports only a small selection of the builtin procedures. It was written to compile one specific program, and it is not likely to be able to compile other programs without modification.

Please let the author know if you would like to use elice to compile other free software programs and need help extending it.


Report bugs to <eligo [at] clueonic.net>.


Written by Richard Braakman.


Copyright 2008 Richard Braakman. Published under the GNU GPL version 2 or later. See the COPYING file for details. There are additional permissions for the use of the runtime library.


elice was written specifically to free the game Lost Labyrinth (http://www.lostlabyrinth.com/) and to make it playable on the author's amd64 system. Lost Labyrinth is a free software game published under the GNU GPL, but it is written in a language that had a proprietary compiler, and that compiler supported a limited set of target platforms which did not include 64-bit Linux.

Under the battle cry of "It's BASIC, how hard can it be?" the author of elice started to write a free compiler. Most of the work was done in September 2006 and it resulted in a playable game, but the compiler was not maintained and was not able to compile newer versions of Lost Labyrinth.

The first public version of elice was released in the summer of 2008, when it had been upgraded to support PureBasic version 4 and was ready for inclusion in the build system of Lost Labyrinth.

Much thanks goes to Markus D[:o]bele for having faith in early versions of elice and relying on it to build the Linux version of Lost Labyrinth.