9. Build System¶
Vala is built using the standard GNU Autotools. The built executables are actually stored in .libs directories and wrapped by scripts. Therefore to debug, follow these instructions:
./configure uses the AC_PATH_PROG macro to choose the valac which is on your path, or one specified in the VALAC environment variable. Therefore, to build Vala with your own valac, type this, for example:
VALAC=$HOME/dev/vala-x.y.z/compiler/valac ./configure --prefix=$HOME/prefix
9.1. Out-of-tree build¶
An out-of-tree build does not properly work yet. Out-of-tree builds have the advantage that your source tree is not cluttered with built files. Suppose you have vala checked out in ~/dev/vala.
rodney@solaria:~/dev % git clone https://gitlab.gnome.org/GNOME/vala.git
rodney@solaria:~/dev % ls vala
fixme fixme fixme fixme
aclocal.m4 config.log gobject-introspection README
AUTHORS config.status INSTALL stamp-h1
autogen.sh config.sub install-sh tests
autom4te.cache configure libtool vala
ccode configure.ac ltmain.sh vala-1.0.pc
ChangeLog COPYING MAINTAINERS vala-1.0.pc.in
compile depcomp Makefile vapi
compiler doc Makefile.am vapigen
config.guess gee Makefile.in ylwrap
config.h gen-project missing
config.h.in gobject NEWS
fixme fixme fixme fixme
rodney@solaria:~/dev % mkdir buildvala
rodney@solaria:~/dev % cd buildvala
rodney@solaria:~/dev/buildvala % ../vala/autogen.sh --prefix=$HOME/dev/prefix
rodney@solaria:~/dev/buildvala % make
All Makefiles, etc, generated by configure will be put in the buildvala directory and you can run make directly from there.