Redo build script to directly call the compiler + limited compiler auto-detection.

No rdmd is necessary anymore and the call to "uname -a" has been changed to
"lsb_release -i" to detect the distribution more reliably. This needs to be
properly fixed, though, by looking at the GCC version or by using a
workaround that works on older _and_ newer versions.