Project ... cannot be opened because it is missing its project.pbxproj file
<p>I recently downloaded LLVM-3.9 and built XCode project files for it with:</p>

<pre><code>mkdir llvm-3.9.0.XCode # The .XCode in the name was probably a bad idea
cd llvm-3.9.0.XCode
cmake -G Xcode ../llvm-3.9.0.src/
</code></pre>

<p>The cmake then generated a valid looking XCode project files.
Then when I tried opening the project directory with XCode, I kept getting error:</p>

<pre><code>Project .../llvm-3.9.0.XCode cannot be opened because it is missing its project.pbxproj file.
</code></pre>

<p>Apparently this error message is often the result of corrupt project files, but this is not the problem in my case. It seems this error can be shown due to different reasons. Here are some similar, but not identical questions that did not help me:</p>

<ul>
<li><p><a href="https://stackoverflow.com/questions/12143281/project-xcodeproj-cannot-be-opened-because-it-is-missing-its-project-pbxproj">One about merge problems.</a></p></li>
<li><p><a href="https://stackoverflow.com/questions/3054063/missing-project-pbxproj-file">A question about where the file shoud be.</a> </p></li>
<li><p><a href="https://stackoverflow.com/questions/21812805/xcode-project-error-xcodeproj-cannot-be-opened-because-it-is-missing-its-projec">One about dropbox problems?</a></p></li>
<li><p><a href="https://stackoverflow.com/questions/361799/unable-to-open-project-cannot-be-opened-because-the-project-file-cannot-be-pa">One where the problem seems to be corrupt project files</a></p></li>
<li><p><a href="https://stackoverflow.com/questions/19548153/project-users-x-desktop-x-x-xcodeproj-cannot-be-opened-because-it-is-missing-it">One where the problem was permissions</a></p></li>
</ul>