<html>
<head>
<base href="https://llvm.org/bugs/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW " title="NEW --- - check-libcxx and check-libcxxabi doesn't work in bootstrap builds on OS X" href="https://urldefense.proofpoint.com/v2/url?u=https-3A__llvm.org_bugs_show-5Fbug.cgi-3Fid-3D24068&d=AwMBaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=pF93YEPyB-J_PERP4DUZOJDzFVX5ZQ57vQk33wu0vio&m=fK5-aZ5tFREWr89bJDkuoaI9y9ib-SMJejcNsQnHU1I&s=0x-NRKm_1BHQ6tfUWbjmEpJacmBPHSPb80xqrE_5lis&e=">24068</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>check-libcxx and check-libcxxabi doesn't work in bootstrap builds on OS X
</td>
</tr>
<tr>
<th>Product</th>
<td>libc++abi
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>All
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>All Bugs
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>nicolasweber@gmx.de
</td>
</tr>
<tr>
<th>CC</th>
<td>llvmbugs@cs.uiuc.edu, mclow.lists@gmail.com
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr></table>
<p>
<div>
<pre>A locally built clang doesn't know where to find system headers on OS X, so one
has to pass `-isysroot $(xcrun --show-sdk-path)` to it to make that work.
So for a bootstrap build, the cmake invocation is something like
cmake -GNinja \
-DCMAKE_BUILD_TYPE=Release \
-DLLVM_ENABLE_ASSERTIONS=ON \
-DCMAKE_C_COMPILER="my/built/clang" \
-DCMAKE_CXX_COMPILER="my/built/clang++" \
-DCMAKE_C_FLAGS="-isysroot /output/of/xcrun" \
-DCMAKE_CXX_FLAGS="-isysroot /output/of/xrun"
This works well almost everywhere, but the libcxxabi tests all fail with
something like:
FAIL: libc++abi :: test_demangle.pass.cpp (41 of 41)
******************** TEST 'libc++abi :: test_demangle.pass.cpp' FAILED
********************
Command:
['/Users/thakis/src/chromefetch/src/third_party/llvm-build/Release+Asserts/bin/clang++',
'-o',
'/Volumes/MacintoshHD2/src/llvm-build/projects/libcxxabi/test/Output/test_demangle.pass.cpp.o',
'-x', 'c++',
'/Volumes/MacintoshHD2/src/llvm-svn/projects/libcxxabi/test/test_demangle.pass.cpp',
'-c', '-v', '-DLIBCXXABI_NO_TIMER', '-std=c++11', '-nostdinc++',
'-I/Users/thakis/src/llvm-svn/projects/libcxx/include',
'-I/Users/thakis/src/llvm-svn/projects/libcxxabi/include']
Exit Code: 1
Standard Error:
--
clang version 3.7.0 (trunk 241602)
Target: x86_64-apple-darwin13.4.0
Thread model: posix
"/Volumes/MacintoshHD2/src/chromefetch/src/third_party/llvm-build/Release+Asserts/bin/clang-3.7"
-cc1 -triple x86_64-apple-macosx10.9.0 -emit-obj -mrelax-all -disable-free
-main-file-name test_demangle.pass.cpp -mrelocation-model pic -pic-level 2
-mthread-model posix -mdisable-fp-elim -masm-verbose -munwind-tables
-target-cpu core2 -target-linker-version 241.9 -v -dwarf-column-info
-coverage-file
/Volumes/MacintoshHD2/src/llvm-build/projects/libcxxabi/test/Output/test_demangle.pass.cpp.o
-nostdinc++ -resource-dir
/Volumes/MacintoshHD2/src/chromefetch/src/third_party/llvm-build/Release+Asserts/bin/../lib/clang/3.7.0
-D LIBCXXABI_NO_TIMER -I /Users/thakis/src/llvm-svn/projects/libcxx/include -I
/Users/thakis/src/llvm-svn/projects/libcxxabi/include -stdlib=libc++ -std=c++11
-fdeprecated-macro -fdebug-compilation-dir
/Users/thakis/src/llvm-build/projects/libcxxabi/test -ferror-limit 19
-fmessage-length 0 -stack-protector 1 -mstackrealign -fblocks
-fobjc-runtime=macosx-10.9.0 -fencode-extended-block-signature -fcxx-exceptions
-fexceptions -fmax-type-align=16 -fdiagnostics-show-option -o
/Volumes/MacintoshHD2/src/llvm-build/projects/libcxxabi/test/Output/test_demangle.pass.cpp.o
-x c++
/Volumes/MacintoshHD2/src/llvm-svn/projects/libcxxabi/test/test_demangle.pass.cpp
clang -cc1 version 3.7.0 based upon LLVM 3.7.0svn default target
x86_64-apple-darwin13.4.0
ignoring nonexistent directory "/usr/local/include"
ignoring nonexistent directory "/usr/include"
#include "..." search starts here:
#include <...> search starts here:
/Users/thakis/src/llvm-svn/projects/libcxx/include
/Users/thakis/src/llvm-svn/projects/libcxxabi/include
/Volumes/MacintoshHD2/src/chromefetch/src/third_party/llvm-build/Release+Asserts/bin/../lib/clang/3.7.0/include
/System/Library/Frameworks (framework directory)
/Library/Frameworks (framework directory)
End of search list.
In file included from
/Volumes/MacintoshHD2/src/llvm-svn/projects/libcxxabi/test/test_demangle.pass.cpp:11:
In file included from
/Users/thakis/src/llvm-svn/projects/libcxx/include/iostream:38:
In file included from
/Users/thakis/src/llvm-svn/projects/libcxx/include/ios:215:
/Users/thakis/src/llvm-svn/projects/libcxx/include/iosfwd:90:10: fatal error:
'wchar.h' file not found
#include <wchar.h> // for mbstate_t
^
1 error generated.
--
Compilation failed unexpectedly!
It looks like the isysroot flag isn't passed on to the libcxxabi test
invocations. check-libcxx has the same problem.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>