<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 --- - clang-format fails to link after libc++ cmake change in r243503" href="https://urldefense.proofpoint.com/v2/url?u=https-3A__llvm.org_bugs_show-5Fbug.cgi-3Fid-3D24306&d=AwMBaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=pF93YEPyB-J_PERP4DUZOJDzFVX5ZQ57vQk33wu0vio&m=h3x4gPK9LCYv-3cM7YQU74aH5nErOW25pDmv-V5cdL4&s=DHLU43b1OcxpV1xNcb7xM53NsF-uQ6mcL-o7lP21fcA&e=">24306</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>clang-format fails to link after libc++ cmake change in r243503
</td>
</tr>
<tr>
<th>Product</th>
<td>libc++
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux
</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>unassignedclangbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>hans@chromium.org
</td>
</tr>
<tr>
<th>CC</th>
<td>eric@efcs.ca, llvmbugs@cs.uiuc.edu, mclow.lists@gmail.com, nicolasweber@gmx.de
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr></table>
<p>
<div>
<pre>Steps to reproduce on a Mac:
$ git clone <a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__llvm.org_git_llvm.git&d=AwMBaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=pF93YEPyB-J_PERP4DUZOJDzFVX5ZQ57vQk33wu0vio&m=h3x4gPK9LCYv-3cM7YQU74aH5nErOW25pDmv-V5cdL4&s=YbypSrd8q8ziKwS_aYUTAL1xJgMUCwRY4sgEImNFNQA&e=">http://llvm.org/git/llvm.git</a>
$ git clone <a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__llvm.org_git_clang.git&d=AwMBaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=pF93YEPyB-J_PERP4DUZOJDzFVX5ZQ57vQk33wu0vio&m=h3x4gPK9LCYv-3cM7YQU74aH5nErOW25pDmv-V5cdL4&s=ZK1J75nfDIu_07WxNkcMl16_GB9955CxcRuVZFJQJnY&e=">http://llvm.org/git/clang.git</a> llvm/tools/clang
$ git clone <a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__llvm.org_git_libcxx.git&d=AwMBaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=pF93YEPyB-J_PERP4DUZOJDzFVX5ZQ57vQk33wu0vio&m=h3x4gPK9LCYv-3cM7YQU74aH5nErOW25pDmv-V5cdL4&s=wLGOASwkmOBEqJLQkgX6KlFJSbtCYx8LYvxec3mooGI&e=">http://llvm.org/git/libcxx.git</a> llvm/projects/libcxx
$ git clone <a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__llvm.org_git_libcxxabi.git&d=AwMBaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=pF93YEPyB-J_PERP4DUZOJDzFVX5ZQ57vQk33wu0vio&m=h3x4gPK9LCYv-3cM7YQU74aH5nErOW25pDmv-V5cdL4&s=ZpaJEB8h4amwMO28zwFcCLo2apgFTeNpJ_qfpli_pTg&e=">http://llvm.org/git/libcxxabi.git</a> llvm/projects/libcxxabi
$ mkdir -p llvm/build
$ cd llvm/build
$ cmake -GNinja ..
$ ninja clang-format
[227/227] Linking CXX executable bin/clang-format
FAILED: : && /usr/bin/c++ -fPIC -fvisibility-inlines-hidden -Wall -W
-Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers
-pedantic -Wno-long-long -Wcovered-switch-default -Wnon-virtual-dtor -std=c++11
-fcolor-diagnostics -fno-common -Woverloaded-virtual -fno-strict-aliasing
-Wno-nested-anon-types -Wl,-search_paths_first -Wl,-headerpad_max_install_names
-Wl,-dead_strip
tools/clang/tools/clang-format/CMakeFiles/clang-format.dir/ClangFormat.cpp.o
-o bin/clang-format lib/libLLVMSupport.a lib/libclangBasic.a
lib/libclangFormat.a lib/libclangRewrite.a lib/libclangToolingCore.a -lcurses
-lpthread -lz -lm -Wl,-rpath,@executable_path/../lib && :
Undefined symbols for architecture x86_64:
"clang::Token::isObjCAtKeyword(clang::tok::ObjCKeywordKind) const",
referenced from:
clang::format::FormatToken::isObjCAtKeyword(clang::tok::ObjCKeywordKind)
const in libclangFormat.a(TokenAnnotator.cpp.o)
clang::format::UnwrappedLineParser::parseTryCatch() in
libclangFormat.a(UnwrappedLineParser.cpp.o)
clang::format::UnwrappedLineParser::parseObjCUntilAtEnd() in
libclangFormat.a(UnwrappedLineParser.cpp.o)
"clang::Lexer::MeasureTokenLength(clang::SourceLocation, clang::SourceManager
const&, clang::LangOptions const&)", referenced from:
clang::tooling::getRangeSize(clang::SourceManager const&,
clang::CharSourceRange const&, clang::LangOptions const&) in
libclangToolingCore.a(Replacement.cpp.o)
"clang::Lexer::Lex(clang::Token&)", referenced from:
clang::Lexer::LexFromRawLexer(clang::Token&) in
libclangFormat.a(Format.cpp.o)
"clang::Lexer::Lexer(clang::FileID, llvm::MemoryBuffer const*,
clang::SourceManager const&, clang::LangOptions const&)", referenced from:
clang::format::(anonymous
namespace)::FormatTokenLexer::FormatTokenLexer(clang::SourceManager&,
clang::FileID, clang::format::FormatStyle&, clang::format::encoding::Encoding)
in libclangFormat.a(Format.cpp.o)
"clang::Token::getObjCKeywordID() const", referenced from:
clang::format::TokenAnnotator::canBreakBefore(clang::format::AnnotatedLine
const&, clang::format::FormatToken const&) in
libclangFormat.a(TokenAnnotator.cpp.o)
clang::format::TokenAnnotator::spaceRequiredBetween(clang::format::AnnotatedLine
const&, clang::format::FormatToken const&, clang::format::FormatToken const&)
in libclangFormat.a(TokenAnnotator.cpp.o)
clang::format::(anonymous
namespace)::AnnotatingParser::determineTokenType(clang::format::FormatToken&)
in libclangFormat.a(TokenAnnotator.cpp.o)
clang::format::UnwrappedLineParser::parseStructuralElement() in
libclangFormat.a(UnwrappedLineParser.cpp.o)
"clang::Lexer::Lexer(clang::SourceLocation, clang::LangOptions const&, char
const*, char const*, char const*)", referenced from:
clang::format::(anonymous
namespace)::FormatTokenLexer::resetLexer(unsigned int) in
libclangFormat.a(Format.cpp.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
ninja: build stopped: subcommand failed.
Reverting r243503 makes the error go away.</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>