We have a number of products that consist of a large number of modules, some of which are shared between some of the products. They are spread out over a few version control repositories.
Products are built by master Ant scripts that are responsible for checking out all modules and building them in the correct order. The modules don't have release cycles of their own.
Now, I'd very much like to go to declarative dependency management, but it seems that all solutions (Maven, Ivy) depend on artifacts rather than on source code under version control. Depending on artifacts would turn things on the head for us, so I'd rather not. I'd like something like Ivy, but where I can say that my product depend on modules foo, bar and baz (branch 2.0) and it would check out the source code from one or more source code managers (specified in some configuration) to a flat workspace.
I plan to use gradle for building, so a solution that fits with that would be much appreciated...