<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<style>
<!--
@font-face
        {font-family:Calibri}
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif"}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline}
a:visited, span.MsoHyperlinkFollowed
        {color:purple;
        text-decoration:underline}
pre
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New"}
span.EmailStyle17
        {font-family:"Calibri","sans-serif";
        color:windowtext}
span.HTMLPreformattedChar
        {font-family:"Courier New"}
.MsoChpDefault
        {}
@page WordSection1
        {margin:1.0in 1.0in 1.0in 1.0in}
div.WordSection1
        {}
-->
</style>
</head>
<body lang="EN-US" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal">Hello,</p>
<p class="MsoNormal">&nbsp;</p>
<p class="MsoNormal">I recently upgraded to Xcode v5 on Mac OSX and started getting build failures.&nbsp; Below is a simplified project that produces the same problem, followed by the error message generated by Xcode.&nbsp; The problem occurs with version v5 but not
 v4.6.x of Xcode.&nbsp; I&#8217;m running CMake 2.8.10.2.</p>
<p class="MsoNormal">&nbsp;</p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">::::::::::::::::</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">CMakeLists.txt</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">::::::::::::::::</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">cmake_minimum_required ( VERSION 2.8.8 )</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">project( test )</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">add_library( a_obj OBJECT t1.c t2.c )</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">add_library( b_obj OBJECT t3.c t4.c )</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">add_library( a dummy.c $&lt;TARGET_OBJECTS:a_obj&gt; )</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">add_library( b dummy.c $&lt;TARGET_OBJECTS:b_obj&gt; )</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">add_executable( t t.c )</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">target_link_libraries( t a b )</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">::::::::::::::<i></i></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">t.c</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">::::::::::::::<i></i></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">#include &lt;stdio.h&gt;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">int func1( int a );</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">int func2( int a );</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">int func3( int a );</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">int func4( int a );</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">int main()</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">{</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;&nbsp;&nbsp; int a = 100;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;&nbsp;&nbsp; printf( &quot;%d %d %d %d %d\n&quot;, a, func1(a), func2(a), func3(a), func4(a) );</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;&nbsp;&nbsp; return 0;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">}</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">::::::::::::::<i></i></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">t1.c</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">::::::::::::::<i></i></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">int func1( int a )</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">{</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;&nbsp;&nbsp; return a*1;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">}</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">::::::::::::::<i></i></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">t2.c</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">::::::::::::::<i></i></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">int func2( int a )</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">{</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;&nbsp;&nbsp; return a*2;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">}</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">::::::::::::::<i></i></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">t3.c</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">::::::::::::::<i></i></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">int func3( int a )</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">{</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;&nbsp;&nbsp; return a*3;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">}</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">::::::::::::::<i></i></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">t4.c</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">::::::::::::::<i></i></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">int func4( int a )</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">{</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;&nbsp;&nbsp; return a*4;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">}</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">dummy.c is empty</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:12.0pt">When I run CMake, no errors; running xcodebuild gives:</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool: can't open file: /Users/jschenck/TestBuild/test.build/Release/a_obj.build/Objects-normal/undefined_arch/t1.o
 (No such file or directory)</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool: can't open file: /Users/jschenck/TestBuild/test.build/Release/a_obj.build/Objects-normal/undefined_arch/t2.o
 (No such file or directory)</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">Command /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool failed with exit code 1</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:12.0pt">The .o files can instead be found here:</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">&nbsp;</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">$ find . -name t1.o</span></p>
<p class="MsoNormal"><span style="font-size:10.0pt; font-family:&quot;Courier New&quot;">./test.build/Release/a_obj.build/Objects-normal/x86_64/t1.o</span></p>
<p class="MsoNormal">&nbsp;</p>
<p class="MsoNormal">&nbsp;</p>
<p class="MsoNormal">Thanks for your help.&nbsp; (Sorry for not running this on the latest version of CMake, but I rolled back Xcode to an earlier version and now will have a hard time reproducing it.&nbsp; If necessary, I can &#8220;upgrade&#8221; again.)</p>
<p class="MsoNormal">&nbsp;</p>
<p class="MsoNormal">Regards,</p>
<p class="MsoNormal">Jeff Schenck</p>
<p class="MsoNormal">&nbsp;</p>
</div>
<br>
<hr>
<font face="Courier New" color="Black" size="3"><br>
Notice:<br>
This message and any included attachments are intended only for the use of the addressee, and may contain information that is privileged or confidential. If you are not the intended recipient, you are hereby notified that any dissemination, distribution or
 copying of this communication is strictly prohibited. If you have received this communication in error, please destroy the original message and any copies or printouts hereof.<br>
</font>
<br clear=all> 
</body>
</html>