[PATCH] D38267: CMake: Add option to set LLVM_ENABLE_DUMP

Matthias Braun via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 26 15:30:40 PDT 2017


MatzeB created this revision.
Herald added subscribers: mgorny, mcrosier.

Repository:
  rL LLVM

https://reviews.llvm.org/D38267

Files:
  CMakeLists.txt
  cmake/modules/HandleLLVMOptions.cmake


Index: cmake/modules/HandleLLVMOptions.cmake
===================================================================
--- cmake/modules/HandleLLVMOptions.cmake
+++ cmake/modules/HandleLLVMOptions.cmake
@@ -84,6 +84,10 @@
   add_definitions(-D_GLIBCXX_DEBUG)
 endif()
 
+if(LLVM_ENABLE_DUMP)
+  add_definitions(-DLLVM_ENABLE_DUMP)
+endif()
+
 string(TOUPPER "${LLVM_ABI_BREAKING_CHECKS}" uppercase_LLVM_ABI_BREAKING_CHECKS)
 
 if( uppercase_LLVM_ABI_BREAKING_CHECKS STREQUAL "WITH_ASSERTS" )
Index: CMakeLists.txt
===================================================================
--- CMakeLists.txt
+++ CMakeLists.txt
@@ -396,6 +396,8 @@
 
 option(LLVM_ENABLE_EXPENSIVE_CHECKS "Enable expensive checks" OFF)
 
+option(LLVM_ENABLE_DUMP "Enable dump functions in release builds" OFF)
+
 set(LLVM_ABI_BREAKING_CHECKS "WITH_ASSERTS" CACHE STRING
   "Enable abi-breaking checks.  Can be WITH_ASSERTS, FORCE_ON or FORCE_OFF.")
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D38267.116628.patch
Type: text/x-patch
Size: 919 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170926/49cd2e74/attachment.bin>


More information about the llvm-commits mailing list