Lazy loading

Implement lazy loading for some of the bigger libraries that are not
always required. Improves startup time.