This is in cmake detection code though, the options you set for your build have no bearing there right?<br><br>This looks like a bug in cmake to me, perhaps a newer cmake version can fix it?<br><div class="gmail_quote"><div dir="ltr">On Tue, May 2, 2017 at 3:24 AM Pavel Labath via lldb-dev <<a href="mailto:lldb-dev@lists.llvm.org">lldb-dev@lists.llvm.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">What's the cmake command you are using?<br>
<br>
It sounds like you somehow ended up enabling -Werror, which is<br>
confusing the backtrace-detection code (and probably most of the other<br>
cmake compile checks).<br>
<br>
One of the workarounds would be to disable -Werror.<br>
<br>
pl<br>
<br>
On 28 April 2017 at 22:36, Andy Gibbs via lldb-dev<br>
<<a href="mailto:lldb-dev@lists.llvm.org" target="_blank">lldb-dev@lists.llvm.org</a>> wrote:<br>
> Hi,<br>
><br>
><br>
> I am having a problem building the 4.0 release branch of LLDB on Debian<br>
> Stretch. Cmake returns the following fault:<br>
><br>
><br>
> -- LLDB version: 4.0.0<br>
> -- Found LibXml2: /usr/lib/x86_64-linux-gnu/libxml2.so (found version<br>
> "2.9.4")<br>
> -- Performing Test HAVE_PROCESS_VM_READV<br>
> -- Performing Test HAVE_PROCESS_VM_READV - Success<br>
> -- Found Curses: /usr/lib/x86_64-linux-gnu/libcurses.so<br>
> -- Looking for __GLIBCXX__<br>
> -- Looking for __GLIBCXX__ - found<br>
> -- Performing Test LLDB_USING_LIBSTDCXX_4_9<br>
> -- Performing Test LLDB_USING_LIBSTDCXX_4_9 - Success<br>
> -- Looking for backtrace<br>
> -- Looking for backtrace - not found<br>
> -- Could NOT find Backtrace (missing: Backtrace_LIBRARY)<br>
> -- Found Doxygen: /usr/bin/doxygen (found version "1.8.13")<br>
> -- Found SWIG: /usr/bin/swig3.0 (found version "3.0.10")<br>
> -- Performing Test CXX_SUPPORTS_NO_MACRO_REDEFINED<br>
> -- Performing Test CXX_SUPPORTS_NO_MACRO_REDEFINED - Success<br>
> -- Symbols (liblldb): exporting all symbols from the lldb namespace<br>
> CMake Error: The following variables are used in this project, but they<br>
> are set to NOTFOUND.<br>
> Please set them or make sure they are set and tested correctly in the<br>
> CMake files:<br>
> Backtrace_LIBRARY (ADVANCED)<br>
> linked by target "liblldb" in directory<br>
> clang-4.0/tools/lldb/source/API<br>
> linked by target "LLDBBreakpointTests" in directory<br>
> clang-4.0/tools/lldb/unittests/Breakpoint<br>
> linked by target "LLDBCoreTests" in directory<br>
> clang-4.0/tools/lldb/unittests/Core<br>
> linked by target "EditlineTests" in directory<br>
> clang-4.0/tools/lldb/unittests/Editline<br>
> linked by target "ExpressionTests" in directory<br>
> clang-4.0/tools/lldb/unittests/Expression<br>
> linked by target "HostTests" in directory<br>
> clang-4.0/tools/lldb/unittests/Host<br>
> linked by target "InterpreterTests" in directory<br>
> clang-4.0/tools/lldb/unittests/Interpreter<br>
> linked by target "LanguageCPlusPlusTests" in directory<br>
> clang-4.0/tools/lldb/unittests/Language/CPlusPlus<br>
> linked by target "LLDBPlatformTests" in directory<br>
> clang-4.0/tools/lldb/unittests/Platform<br>
> linked by target "ProcessGdbRemoteTests" in directory<br>
> clang-4.0/tools/lldb/unittests/Process/gdb-remote<br>
> linked by target "LLDBMinidumpTests" in directory<br>
> clang-4.0/tools/lldb/unittests/Process/minidump<br>
> linked by target "ScriptInterpreterPythonTests" in directory<br>
> clang-4.0/tools/lldb/unittests/ScriptInterpreter/Python<br>
> linked by target "SymbolTests" in directory<br>
> clang-4.0/tools/lldb/unittests/Symbol<br>
> linked by target "SymbolFileDWARFTests" in directory<br>
> clang-4.0/tools/lldb/unittests/SymbolFile/DWARF<br>
> linked by target "UnwindAssemblyx86Tests" in directory<br>
> clang-4.0/tools/lldb/unittests/UnwindAssembly/x86<br>
> linked by target "UtilityTests" in directory<br>
> clang-4.0/tools/lldb/unittests/Utility<br>
><br>
> -- Configuring incomplete, errors occurred!<br>
> See also "build-4.0/bootstrap/CMakeFiles/CMakeOutput.log".<br>
> See also "build-4.0/bootstrap/CMakeFiles/CMakeError.log".<br>
><br>
><br>
><br>
> The output from CMakeError.log is:<br>
><br>
><br>
> Determining if the backtrace exist failed with the following output:<br>
> Change Dir: build-4.0/bootstrap/CMakeFiles/CMakeTmp<br>
><br>
> Run Build Command:"build-4.0/bin/ninja" "cmTC_1e735"<br>
> [1/2] Building C object CMakeFiles/cmTC_1e735.dir/CheckSymbolExists.c.o<br>
> FAILED: CMakeFiles/cmTC_1e735.dir/CheckSymbolExists.c.o<br>
> /usr/bin/cc -fPIC -Wall -W -Wno-unused-parameter -Wwrite-strings<br>
> -Wno-missing-field-initializers -pedantic -Wno-long-long -Wno-comment<br>
> -Werror -Werror=date-time -ffunction-sections -fdata-sections -o<br>
> CMakeFiles/cmTC_1e735.dir/CheckSymbolExists.c.o -c<br>
> build-4.0/bootstrap/CMakeFiles/CMakeTmp/CheckSymbolExists.c<br>
> build-4.0/bootstrap/CMakeFiles/CMakeTmp/CheckSymbolExists.c: In function<br>
> ‘main’:<br>
> build-4.0/bootstrap/CMakeFiles/CMakeTmp/CheckSymbolExists.c:8:11: error:<br>
> ISO C forbids conversion of function pointer to object pointer type<br>
> [-Werror=pedantic]<br>
> return ((int*)(&backtrace))[argc];<br>
> ^<br>
> cc1: all warnings being treated as errors<br>
> ninja: build stopped: subcommand failed.<br>
><br>
> File build-4.0/bootstrap/CMakeFiles/CMakeTmp/CheckSymbolExists.c:<br>
> /* */<br>
> #include <execinfo.h><br>
><br>
> int main(int argc, char** argv)<br>
> {<br>
> (void)argv;<br>
> #ifndef backtrace<br>
> return ((int*)(&backtrace))[argc];<br>
> #else<br>
> (void)argc;<br>
> return 0;<br>
> #endif<br>
> }<br>
><br>
><br>
> It seems that the detection routine is invalid. The gcc in use is 6.3.0.<br>
> Anyone any idea how to fix / work around this problem?<br>
><br>
><br>
> Many thanks,<br>
><br>
><br>
> Andy<br>
><br>
><br>
><br>
><br>
><br>
><br>
> _______________________________________________<br>
> lldb-dev mailing list<br>
> <a href="mailto:lldb-dev@lists.llvm.org" target="_blank">lldb-dev@lists.llvm.org</a><br>
> <a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-dev</a><br>
><br>
_______________________________________________<br>
lldb-dev mailing list<br>
<a href="mailto:lldb-dev@lists.llvm.org" target="_blank">lldb-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-dev</a><br>
</blockquote></div>