Reorganised to support an automated build.