Fixed a bug with paths on OSX and Linux.
Bugfixes to autoexec and cache handling.