Properly use Makefiles for Prolog.