Sort out automatic download of dependencies
Modularise build