Bug fix: clean and cleanall can now clean up correctly.

The introduction of MODE resulted in clean and cleanall incorrectly only
cleaning up the program binaries (and not the library files) if both
programs and libraries were compiled.  This is now fixed so both kinds
of targets are removed if previously created.