Fixed some build-related issues.
Optmized autoloader.