[libunwind] r271462 - Add status/warning message for 32 bit builds

Eric Fiselier via cfe-commits cfe-commits at lists.llvm.org
Wed Jun 1 18:19:53 PDT 2016


Author: ericwf
Date: Wed Jun  1 20:19:52 2016
New Revision: 271462

URL: http://llvm.org/viewvc/llvm-project?rev=271462&view=rev
Log:
Add status/warning message for 32 bit builds

Modified:
    libunwind/trunk/CMakeLists.txt

Modified: libunwind/trunk/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/libunwind/trunk/CMakeLists.txt?rev=271462&r1=271461&r2=271462&view=diff
==============================================================================
--- libunwind/trunk/CMakeLists.txt (original)
+++ libunwind/trunk/CMakeLists.txt Wed Jun  1 20:19:52 2016
@@ -110,6 +110,16 @@ set(LIBUNWIND_TARGET_TRIPLE "" CACHE STR
 set(LIBUNWIND_GCC_TOOLCHAIN "" CACHE PATH "GCC toolchain for cross compiling.")
 set(LIBUNWIND_SYSROOT "" CACHE PATH "Sysroot for cross compiling.")
 
+
+# Check that we can build with 32 bits if requested.
+if (CMAKE_SIZEOF_VOID_P EQUAL 8 AND NOT WIN32)
+  if (LIBUNWIND_BUILD_32_BITS AND NOT LLVM_BUILD_32_BITS) # Don't duplicate the output from LLVM
+    message(STATUS "Building 32 bits executables and libraries.")
+  endif()
+elseif(LIBUNWIND_BUILD_32_BITS)
+  message(FATAL_ERROR "LIBUNWIND_BUILD_32_BITS=ON is not supported on this platform.")
+endif()
+
 #===============================================================================
 # Configure System
 #===============================================================================




More information about the cfe-commits mailing list