[llvm-branch-commits] [llvm] 8f1e0dc - fix some Wundef warnings in public headers
Author: Jameson Nash Date: 2020-11-23T20:17:46-05:00 New Revision: 8f1e0dcbb090243423faa4228ba58ddbae909c70 URL: https://github.com/llvm/llvm-project/commit/8f1e0dcbb090243423faa4228ba58ddbae909c70 DIFF: https://github.com/llvm/llvm-project/commit/8f1e0dcbb090243423faa4228ba58ddbae909c70.diff LOG: fix some Wundef warnings in public headers Differential Revision: https://reviews.llvm.org/D91094 Added: Modified: llvm/include/llvm/ADT/Statistic.h llvm/include/llvm/Config/abi-breaking.h.cmake Removed: diff --git a/llvm/include/llvm/ADT/Statistic.h b/llvm/include/llvm/ADT/Statistic.h index d7aff6c5939a..aa338ccff19a 100644 --- a/llvm/include/llvm/ADT/Statistic.h +++ b/llvm/include/llvm/ADT/Statistic.h @@ -36,6 +36,8 @@ // configure time. #if !defined(NDEBUG) || LLVM_FORCE_ENABLE_STATS #define LLVM_ENABLE_STATS 1 +#else +#define LLVM_ENABLE_STATS 0 #endif namespace llvm { diff --git a/llvm/include/llvm/Config/abi-breaking.h.cmake b/llvm/include/llvm/Config/abi-breaking.h.cmake index a1ffad660770..2d27e02b1d54 100644 --- a/llvm/include/llvm/Config/abi-breaking.h.cmake +++ b/llvm/include/llvm/Config/abi-breaking.h.cmake @@ -20,7 +20,7 @@ /* Allow selectively disabling link-time mismatch checking so that header-only ADT content from LLVM can be used without linking libSupport. */ -#if !LLVM_DISABLE_ABI_BREAKING_CHECKS_ENFORCING +#if !defined(LLVM_DISABLE_ABI_BREAKING_CHECKS_ENFORCING) || !LLVM_DISABLE_ABI_BREAKING_CHECKS_ENFORCING // ABI_BREAKING_CHECKS protection: provides link-time failure when clients build // mismatch with LLVM ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits
[llvm-branch-commits] [llvm] c01fb64 - repair cygwin build
Author: Jameson Nash Date: 2020-12-03T11:49:16-05:00 New Revision: c01fb6449e1794488f6ec6f1c7792c35325022af URL: https://github.com/llvm/llvm-project/commit/c01fb6449e1794488f6ec6f1c7792c35325022af DIFF: https://github.com/llvm/llvm-project/commit/c01fb6449e1794488f6ec6f1c7792c35325022af.diff LOG: repair cygwin build This is needed for cross-compiling LLVM from Cygwin, but it had gotten deleted in rG2724d9e12960cc1d93eeabbfc9aa1ba041cc Reviewed By: compnerd Differential Revision: https://reviews.llvm.org/D92336 Added: Modified: llvm/CMakeLists.txt Removed: diff --git a/llvm/CMakeLists.txt b/llvm/CMakeLists.txt index c085f889cc4a..9b5cadeed0c4 100644 --- a/llvm/CMakeLists.txt +++ b/llvm/CMakeLists.txt @@ -52,7 +52,13 @@ project(LLVM set(CMAKE_CXX_STANDARD 14 CACHE STRING "C++ standard to conform to") set(CMAKE_CXX_STANDARD_REQUIRED YES) -set(CMAKE_CXX_EXTENSIONS NO) +if (CYGWIN) + # Cygwin is a bit stricter and lack things like 'strdup', 'stricmp', etc in + # c++xx mode. + set(CMAKE_CXX_EXTENSIONS YES) +else() + set(CMAKE_CXX_EXTENSIONS NO) +endif() if (NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES) message(STATUS "No build type selected, default to Debug") ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits