[compiler-rt] r224749 - Change the CMake build to generate full debugging info when COMPILER_RT_DEBUG=ON

Kuba Brecka kuba.brecka at gmail.com
Mon Dec 22 17:52:53 PST 2014


Author: kuba.brecka
Date: Mon Dec 22 19:52:53 2014
New Revision: 224749

URL: http://llvm.org/viewvc/llvm-project?rev=224749&view=rev
Log:
Change the CMake build to generate full debugging info when COMPILER_RT_DEBUG=ON

The compiler-rt CMake build currently uses -gline-tables-only for all builds. While this makes the debugger correctly map source files, debugging of the runtime libraries in general is pretty tough, because you don't see any local variables, parameters, etc. Let's allow emitting full debugging info by setting COMPILER_RT_DEBUG=ON.

Reviewed at http://reviews.llvm.org/D6764


Modified:
    compiler-rt/trunk/CMakeLists.txt

Modified: compiler-rt/trunk/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/CMakeLists.txt?rev=224749&r1=224748&r2=224749&view=diff
==============================================================================
--- compiler-rt/trunk/CMakeLists.txt (original)
+++ compiler-rt/trunk/CMakeLists.txt Mon Dec 22 19:52:53 2014
@@ -256,7 +256,7 @@ if(NOT COMPILER_RT_DEBUG AND NOT MSVC)
 endif()
 
 # Build sanitizer runtimes with debug info.
-if(COMPILER_RT_HAS_GLINE_TABLES_ONLY_FLAG)
+if(COMPILER_RT_HAS_GLINE_TABLES_ONLY_FLAG AND NOT COMPILER_RT_DEBUG)
   list(APPEND SANITIZER_COMMON_CFLAGS -gline-tables-only)
 elseif(COMPILER_RT_HAS_G_FLAG)
   list(APPEND SANITIZER_COMMON_CFLAGS -g)





More information about the llvm-commits mailing list