The GNU Modula-2 front end to GCC

Building GNU Modula-2 from source under GNU/Linux

On a GNU/Linux system you should also be able to build it using these commands. The following commands assume your shell is /bin/bash. To build GNU Modula-2 type:

$ mkdir -p $HOME/opt
$ mkdir -p build-4.1.2
$ cd build-4.1.2
$ ../gcc-4.1.2+gm2-cvs-latest/configure --enable-languages=c,c++,gm2 \
     --disable-multilib --enable-checking=all --prefix=$HOME/opt
$ make "SHELL=/bin/bash"

To install GNU Modula-2, after a successful build, type:

$ make "SHELL=/bin/bash" install
$ cd ..

Now you should be able to perform:

$ export PATH=$HOME/opt/bin:$PATH
$ cd build-4.1.2/gcc/gm2/examples/hello
$ make post-install

which will create an a.out for the infamous hello world example.