Use Compiler API in Loader.

Now our command line always runs through our Compiler API.

Fixes #1324
It makes me sad that we have to do it this way but I don't have better solution at this point.