Improve build system, now pulls in external dependencies and builds them