Compilation & Installation

How to compile and install version 3


Rebuilding compilation toolchain with reconf from Gambas 2 version previous than 2.15.2 require libtool 1.5. This is not true anymore for next versions (including the development version) that now requires libtool 2.x.

So now downgrading libtool is not required anymore.

Development Packages

In order to compile Gambas, you must install the following development packages.

The actual name of these development packages depends on your distribution, so please refer to the distribution specific pages above for more details.

Component Packages Mandriva Ubuntu
Compilation gcc g++ gettext gettext-devel task-c-devel task-c++-devel build-essential
Interpreter libffi libffi-devel libffi-dev
gb.compress.bzlib2 libbz2 libbzip2_1-devel libbz2-dev
gb.compress.zlib libz zlib1-devel

gb.corba libACE libomniORB4 libomniDynamic4 libORBit2-devel libomniorb-devel

gb.crypt - -
gb.db.firebird libfbclient firebird-devel libfbclient2 firebird2.1-dev
gb.db.mysql libmysqlclient, libz libmysql-devel libmysqlclient15-dev
gb.db.odbc libodbc

gb.db.postgresql libpq libpq-devel postgresql-devel libpq-dev
gb.db.sqlite2 libsqlite libsqlite0-devel libsqlite0-dev
gb.db.sqlite3 libsqlite3 libsqlite3-devel libsqlite3-dev
gb.desktop - libxtst-dev
gb.gtk All GTK+ libraries >= 2.10 libgtk+-devel libgtk+2.0_0-devel libgtk2.0-dev libgtkglext1-dev
gb.gtk.svg librsvg2 librsvg2-devel librsvg2-dev libcurl libcurl-devel libcurl4-gnutls-dev
gb.opengl libGL libGLU libmesagl1-devel libmesaglu1-devel

gb.pcre libpcre libpcre-devel libpcre3-dev
gb.pdf libpoppler libpoppler-devel libpoppler-dev libpoppler-glib-dev
gb.qt gb.qt.ext gb.qt.opengl libqt-mt >= 3.3 libqt3-devel libqt3-mt-dev
gb.qt.kde All KDE 3 libraries >= 3.5 libkdecore4-devel kdelibs4-dev
gb.sdl libSDL libSDL_image libSDL_ttf libGL libGLU libSDL-devel libSDL_image-devel libSDL_ttf-devel libmesagl1-devel libmesaglu1-devel libsdl-image1.2-dev
gb.sdl.sound libSDL libSDL_mixer libSDL-devel libSDL_mixer-devel libsdl-sound1.2-dev libsdl-mixer1.2-dev
gb.v4l libjpeg libpng Video4Linux >= 2.0

gb.xml libxml-2.0 libxml2-devel libxml2-dev
gb.xml.xslt libxslt libxslt-devel libxslt1-dev

Other requirements

You must have the right to write to /tmp, otherwise Gambas will not work.

The following versions of GNU tools are needed:

Compiling with older version may or may not work!

How to compile and install Gambas 2

Source package configuration

When you are sure that everything is downloaded, type the following magic sentences in a shell.

'$' represents your shell prompt, and '...' are the messages printed during the configuration and compilation.

First, enter the source top-level directory.

$ cd <path/to/source/directory>

Then, type that to create the configuration scripts.

$ ./reconf-all

Then type that to analyze the current system and configure the package:

$ ./configure -C

If a library or a development package is missing, then you will be warned that some components are disabled.

There are more 'configure' specific explanations in the INSTALL file located in the top-level source directory. I invite you to read them.


If everything is configured without error, then run this command to compile the program:

$ make


If everything compiles without error, then enter this command to install everything:

You must be root to install Gambas on your system.

$ su -c "make install"


$ sudo make install


If you did several successive compilations, after having updated the source from the subversion repository for example, and if something fails during all this process, you can try to "reconfigure" the configuration scripts by typing the following command:

$ ./reconf-all

Then you can run ./configure -C again

If it does not work, I need to know what happened exactly. To do so, type the following command :

$ ( ./configure -C; make; make install ) > output.txt 2>&1

And send me the file "output.txt" by mail, with every other detail about your computer and your distribution you find useful.

Instructions for specific distributions

A  Arch Linux
D  Debian
F  Fedora  · FreeBSD
M  Mageia  · Mandriva
O  OpenSUSE 10.2
P  Pardus
U  Ubuntu

The Development Environment

The Gambas IDE is made with Gambas. In order to compile and use it, you need to compile the following components:

Compiling from Subversion

To compile the latest development version of Gambas from the subversion repository, read the How To Deal With Subversion page.