<html><body><div style="color:#000; background-color:#fff; font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:12pt"><div class="" style="">Hi everyone,</div><div class="" style=""><br class="" style=""></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color: transparent;" class="">I am using CygWin 1.7.31 32-bit. </div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color: transparent;" class=""><span style="background-color: transparent;" class=""><br class="" style=""></span></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal;
background-color: transparent;" class=""><span style="background-color: transparent;" class="">I have downloaded llvm 3.4.2 with clang, compiler-rt and extra clang tools.</span></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color: transparent;" class=""><br class="" style=""></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color: transparent;" class="">I configured llvm and clang in a "build"-directory with the default options (i.e., <span style="font-weight: bold;" class="">../configure</span>).</div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color: transparent;"
class="">I built everything with the default configuration options and using REQUIRES_RTTI=1 (i.e., <span style="font-weight: bold;" class="">make REQUIRES_RTTI=1</span>).</div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color: transparent;" class="">Afterwards, I tried to build <span style="font-size: 12pt;" class="">the</span><span style="font-size: 12pt;" class=""> </span><span style="background-color: transparent;" class="">PrintFunctionNames example <span style="font-weight: bold;" class="">from </span>~/llvm/build/tools/clang/examples/PrintFunctionNames. (i.e., <span style="font-weight: bold;" class="">make </span></span><span style="font-size: 12pt;" class=""><span style="font-weight: bold;" class="">REQUIRES_RTTI=1 BUILD_EXAMPLES=1</span>).</span></div><div style="font-style: normal; font-size:
16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: rgb(0, 0, 0); background-color: transparent;" class=""><br class="" style=""></div><div style="font-style: normal; font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: rgb(0, 0, 0); background-color: transparent;" class="">It compiles successfully, but the l<span style="font-weight: bold;" class="">inking fails</span>.</div><div style="font-style: normal; font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: rgb(0, 0, 0); background-color: transparent;" class=""><br class="" style=""></div><div style="background-color: transparent;" class=""><span style="font-weight: bold;" class="">$ cd ~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames</span></div><div style="background-color: transparent;" class=""><span
style="font-weight: bold;" class="">$ make REQUIRES_RTTI=1 BUILD_EXAMPLES=1</span></div><div style="background-color: transparent;" class=""><br class="" style=""></div><div style="background-color: transparent;" class="">llvm[0]: Linking Release+Asserts Shared Library cygPrintFunctionNames.dll</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x6): <span style="font-weight: bold;" class="">undefined reference to `vtable for clang::ASTConsumer'</span></div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x16): undefined reference to `vtable for clang::ASTConsumer'</div><div style="background-color: transparent;"
class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x26): undefined reference to `vtable for clang::ASTFrontendAction'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x3a): undefined reference to `vtable for clang::ASTFrontendAction'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x42): undefined reference to `clang::FrontendAction::~FrontendAction()'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0xa8): undefined reference to
`clang::FrontendAction::FrontendAction()'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x126): undefined reference to `llvm::raw_ostream::write(char const*, unsigned int)'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x17f): undefined reference to `clang::DeclarationName::getAsString() const'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x187): undefined reference to `llvm::errs()'</div><div style="background-color: transparent;"
class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x1ae): undefined reference to `llvm::raw_ostream::write(char const*, unsigned int)'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x1f4): undefined reference to `llvm::raw_ostream::write(char const*, unsigned int)'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x2c3): undefined reference to `llvm::raw_ostream::write(char const*, unsigned int)'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x301):
undefined reference to `llvm::errs()'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x331): undefined reference to `llvm::raw_ostream::write(char const*, unsigned int)'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x354): undefined reference to `llvm::raw_ostream::write(char const*, unsigned int)'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x387): undefined reference to `llvm::errs()'</div><div style="background-color: transparent;"
class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x49b): undefined reference to `clang::DiagnosticIDs::getCustomDiagID(clang::DiagnosticIDs::Level, llvm::StringRef)'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x503): undefined reference to `clang::DiagnosticsEngine::EmitCurrentDiagnostic(bool)'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x525): undefined reference to `llvm::raw_ostream::write(char const*, unsigned int)'</div><div style="background-color: transparent;"
class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.text+0x2b): undefined reference to `clang::FrontendAction::~FrontendAction()'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.rdata+0x658): undefined reference to `clang::ASTConsumer::HandleInterestingDecl(clang::DeclGroupRef)'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.rdata+0x66c): undefined reference to `clang::ASTConsumer::HandleTopLevelDeclInObjCContainer(clang::DeclGroupRef)'</div><div style="background-color: transparent;"
class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.rdata+0x670): undefined reference to `clang::ASTConsumer::HandleImplicitImportDecl(clang::ImportDecl*)'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.rdata+0x6b4): undefined reference to `clang::ASTFrontendAction::ExecuteAction()'</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.rdata+0x6bc): undefined reference to `clang::FrontendAction::shouldEraseOutputFiles()'</div><div style="background-color: transparent;"
class="">~/llvm-3.4.2.src/build/tools/clang/examples/PrintFunctionNames/Release+Asserts/PrintFunctionNames.o:PrintFunctionNames.cpp:(.rdata+0x6e0): undefined reference to `clang::PluginASTAction::anchor()'</div><div style="background-color: transparent;" class="">collect2: error: ld returned 1 exit status</div><div style="background-color: transparent;" class="">~/llvm-3.4.2.src/Makefile.rules:1167: recipe for target '~/llvm-3.4.2.src/build/Release+Asserts/bin/cygPrintFunctionNames.dll' failed</div><div style="background-color: transparent;" class="">make: *** [~/llvm-3.4.2.src/build/Release+Asserts/bin/cygPrintFunctionNames.dll] Error 1</div><div style="background-color: transparent;" class=""><br class="" style=""></div><div class="" style=""><br class="" style=""></div><div class="" style=""><br class="" style=""></div><div class="" style=""><span style="font-weight: bold;" class="">I have even tried this with the -fno-rtti flag <span class=""
style="">set</span>. And I received the <span class="" style="">same</span> error message.</span></div><div class="" style=""><span style="font-weight: bold;" class="">I also tried it with the </span><span style="font-weight: bold; font-size: 12pt;" class="">ENABLE_CXX11=1. It still does not work.</span></div><div class="" style=""><span style="font-weight: bold; font-size: 12pt;" class=""><br></span></div><div class="" style="">Thanks a lot for your help.</div><div class="" style=""><br class="" style=""></div><div class="" style=""><div class="" style="margin-top: 0.1em; margin-bottom: 0.1em; background-color: transparent;">Kind Regards,</div><div class="" style="margin-top: 0.1em; margin-bottom: 0.1em; background-color: transparent;">Bogdan</div><div class="" style=""><br class="" style=""></div><div class="" style="">P.S. I am experiencing the same problem with llvm 3.5.</div></div><div style="color: rgb(0, 0, 0); font-size: 16px;
font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color: transparent;" class=""><br class="" style=""></div></div></body></html>