Including 'Run Script' phase output files in build
<p>In Xcode 7, you can create 'Run Script' phases in the Build Phases tab. At the bottom of the area, there's an 'Input Files' section and an 'Output Files' section.</p>

<p>I have a script that generates a .cpp file at <code>$(DERIVED_FILE_DIR)/myfile.cpp</code>. The file is listed in the 'Output Files' section of the phase. However, it appears that it's not compiled into my program, as the symbol that it defines are identified as missing by the linker.</p>

<p>How can I tell Xcode to compile this file as well?</p>