title: automake and project dependencies
body: <p>I have a project that I want to build using automake. The project consists of different components or modules, and there are inter module dependencies which require the project to be built in a specific order.</p>
  
  <p>For example:</p>
  
  <pre><code>project dir/
    module1 (core C shared lib)
    module2 (C++ shared lib wrapper around module 1)
    module3 (C++ application with dependency on module2)
    module4 (C library with dependency on module1)
    module5 (C application with dependency on module4)
  </code></pre>
  
  <p>I am relatively new to automake, but I (just about) know how to use it to successfully build a single project.</p>
  
  <p>I would like to have a 'master' project file (if that's possible), which specifies the build order of the projects modules, runs unit tests and fails the entire build process if either:</p>
  
  <ul>
  <li>One of the modules fails to build</li>
  <li>One of the modules fails a unit test</li>
  </ul>
  
  <p>How would I go about writing such a 'master project' file (or invoking any other mechanism) to build projects that have a lot of inter-modular dependencies?</p>