Currently there are two automated methods to test GNU Modula-2. The first method is make gm2.paranoid in which gm2 builds itself and finally the test runs both parent and child generations of the compiler and compares the output. Be warned that this test can take some time to execute. This test is invoked by:
$ cd host-build/gcc ; make gm2.paranoid
The second method used to test GNU Modula-2 is to run the regression test suite. The GNU Modula-2 regression test suite is available for download. To install and run the GNU Modula-2 regression suite you need to have installed the dejagnu and expect packages. Note that you need to ensure that you have at least the following releases of dejagnu components:
$ runtest --version Expect version is 5.42.1 Tcl version is 8.4 Framework version is 1.4.4
otherwise some of the tests may not run.
If you have downloaded the combined GCC and GNU Modula-2 tarball http://floppsie.comp.glam.ac.uk/download/c/gcc-4.1.2+gm2-cvs-latest.tar.gz then this will also contain the GNU Modula-2 testsuite. In this case you can skip over the following cvs and tar commands.
However if you have downloaded GNU Modula-2 using CVS then you will also need to download and position the testsuite. Assuming that the root of the GCC source tree is in the current working directory you can use the following commands to install the test suite:
$ cvs -z3 -d:pserver:anoncvs@cvs.sv.gnu.org:/sources/gm2 co testsuite $ tar cf - testsuite | ( cd gcc-version-GCC/gcc ; tar xf - )
Do not simply move the directory testsuite into gcc-version-GCC/gcc as the GNU Modula-2 regression tests have to be overlaid on top of the gcc testsuite.
Thereafter you can run the GNU Modula-2 testsuite by:
$ cd host-build/gcc $ make check-gm2
Depending on the speed of your computer these tests may take a while to complete.