title: Eclipse CDT C/C++: Include a header file from another project
body: <p>I have two c++ projects in Eclipse CDT <strong>main</strong> and <strong>shared</strong>. In <strong>shared</strong> i have a header called <strong>calc.h</strong>. I want to use this header in <strong>main</strong>, so i did the following:</p>
  
  <ul>
  <li>added <code>#include "calc.h</code> to the relevant files in <strong>main</strong></li>
  <li>In <strong>main</strong>'s <code>properties -&gt; Project references</code> i checked of <strong>shared</strong></li>
  </ul>
  
  <p>I hoped this would work, but I get a <code>fatal error: calc.h: No such file or directory</code> when compiling, so the project reference somehow doesn't work.</p>
  
  <p>I can get it to work by manually adding <strong>shared</strong>'s source folder in <strong>main</strong>'s <code>properties-&gt;C/C++ Build-&gt;Setting-&gt;GCC C++Compiler-&gt;Includes</code>, but my i have a bad feeling that this will become cumbersome on larger projects more complex dependencies. I'll therefore hoped that Eclipse could handle this via project references.</p>
  
  <p>Am I missing something or is manually the only way?</p>