Decouple the source model logic tree from the gsim logic tree

This refactoring make it possible to generate SES without needing the gsim logic tree, as requested in https://bugs.launchpad.net/oq-engine/+bug/1248237

Notice that in order the XML export to work the companion PR on nrmllib is needed:
https://github.com/gem/oq-nrmllib/pull/121

Tests are running on http://ci.openquake.org/job/zdevel_oq-engine/206