Properly build a git submodule with gnu make
I currently try to write a Makefile that build properly a project which contains a git submodule. This submodule have its own set of makefiles and produce several targets at once, including some libraries. This Makefile should have the following properties. Don't rebuild twice the submodule even with parallel build. Update the submodule targets when the submodule code has changed (maybe because I navigated through the revisions of the main repository). Re-link the main project when the submodule library have changed. Don't copy-paste the Makefiles of the submodule in the top-level project (i.e