MDEV-34996 was incomplete it its testing of -stdlib=libc++ as this required -fsanitize=memory
The MY_CHECK_AND_SET_COMPILER_FLAG("-fsanitize=memory prior to MY_CHECK_CXX_COMPILER_FLAG("-stdlib=libc++") doesn't set the CMAKE_REQUIRED_FLAGS so results in:
/source/CMakeLists.txt(249): MY_CHECK_CXX_COMPILER_FLAG(-stdlib=libc++ )
|
/source/cmake/check_compiler_flag.cmake(28): STRING(REGEX REPLACE [-,= +] _ result have_CXX_-stdlib=libc++ )
|
/source/cmake/check_compiler_flag.cmake(29): SET(SAVE_CMAKE_REQUIRED_FLAGS )
|
/source/cmake/check_compiler_flag.cmake(30): SET(CMAKE_REQUIRED_FLAGS -stdlib=libc++ )
|
/source/cmake/check_compiler_flag.cmake(31): CHECK_CXX_SOURCE_COMPILES(int main(void) { return 0; } have_CXX__stdlib_libc__ FAIL_REGEX;argument unused during compilation;FAIL_REGEX;unsupported .*option;FAIL_REGEX;unknown .*option;FAIL_REGEX;unrecognized .*option;FAIL_REGEX;ignoring unknown option;FAIL_REGEX;warning:.*ignored;FAIL_REGEX;warning:.*is valid for.*but not for;FAIL_REGEX;warning:.*redefined;FAIL_REGEX;[Ww]arning: [Oo]ption )
|
-- Performing Test have_CXX__stdlib_libc__
|
-- Performing Test have_CXX__stdlib_libc__ - Failed
|
/source/cmake/check_compiler_flag.cmake(33): SET(CMAKE_REQUIRED_FLAGS )
|
/source/CMakeLists.txt(250): IF(NOT have_CXX__stdlib_libc__ )
|
/source/CMakeLists.txt(251): MESSAGE(FATAL_ERROR C++ Compiler requires support for -stdlib=libc++ )
|
CMake Error at CMakeLists.txt:251 (MESSAGE):
|
C++ Compiler requires support for -stdlib=libc++
|
|
|
-- Configuring incomplete, errors occurred!
|
See also "/build/CMakeFiles/CMakeOutput.log".
|
See also "/build/CMakeFiles/CMakeError.log".
|
buildbot@2f11790aa1e1:/build$ rm -rf .ninja_*
|
buildbot@2f11790aa1e1:/build$ tail -n 30 /build/CMakeFiles/CMakeError.log
|
Change Dir: /build/CMakeFiles/CMakeScratch/TryCompile-RfQ4we
|
|
Run Build Command(s):/usr/bin/ninja cmTC_2cfad && [1/2] Building CXX object CMakeFiles/cmTC_2cfad.dir/src.cxx.o
|
[2/2] Linking CXX executable cmTC_2cfad
|
FAILED: cmTC_2cfad
|
: && /usr/bin/clang++ -stdlib=libc++ -L/msan-libs -Wl,-rpath=/msan-libs CMakeFiles/cmTC_2cfad.dir/src.cxx.o -o cmTC_2cfad && :
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__msan_memset'
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__msan_retval_origin_tls'
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__msan_unpoison'
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__msan_param_origin_tls'
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__msan_memcpy'
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__msan_retval_tls'
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__msan_va_arg_overflow_size_tls'
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__msan_va_arg_origin_tls'
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__sanitizer_dtor_callback_fields'
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__msan_memmove'
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__msan_chain_origin'
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__sanitizer_dtor_callback_vptr'
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__msan_va_arg_tls'
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__msan_warning_with_origin_noreturn'
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__msan_set_alloca_origin_with_descr'
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__msan_init'
|
/usr/bin/ld: /msan-libs/libc++.so.1: undefined reference to `__msan_param_tls'
|
clang++: error: linker command failed with exit code 1 (use -v to see invocation)
|
ninja: build stopped: subcommand failed.
|
- is caused by
-
MDEV-34996
Buildbot MSAN options in buildbot rather than server
-
-
Closed
{"report":{"fcp":1218.5999999046326,"ttfb":290.7999999523163,"pageVisibility":"visible","entityId":132981,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":0.5,"journeyId":"8f28c199-d6f8-4ffc-9d3b-c92bba9c6c26","navigationType":0,"readyForUser":1299.3999998569489,"redirectCount":0,"resourceLoadedEnd":1777.3999998569489,"resourceLoadedStart":298.7999999523163,"resourceTiming":[{"duration":432.7999999523163,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":298.7999999523163,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":298.7999999523163,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":731.5999999046326,"responseStart":0,"secureConnectionStart":0},{"duration":432.69999980926514,"initiatorType":"link","name":"https://jira.mariadb.org/s/7ebd35e77e471bc30ff0eba799ebc151-CDN/lu2cib/820016/12ta74/494e4c556ecbb29f90a3d3b4f09cb99c/_/download/contextbatch/css/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.css?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true&whisper-enabled=true","startTime":299.2000000476837,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":299.2000000476837,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":731.8999998569489,"responseStart":0,"secureConnectionStart":0},{"duration":452.7000000476837,"initiatorType":"script","name":"https://jira.mariadb.org/s/0917945aaa57108d00c5076fea35e069-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":299.39999985694885,"connectEnd":299.39999985694885,"connectStart":299.39999985694885,"domainLookupEnd":299.39999985694885,"domainLookupStart":299.39999985694885,"fetchStart":299.39999985694885,"redirectEnd":0,"redirectStart":0,"requestStart":299.39999985694885,"responseEnd":752.0999999046326,"responseStart":752.0999999046326,"secureConnectionStart":299.39999985694885},{"duration":502.89999985694885,"initiatorType":"script","name":"https://jira.mariadb.org/s/2d8175ec2fa4c816e8023260bd8c1786-CDN/lu2cib/820016/12ta74/494e4c556ecbb29f90a3d3b4f09cb99c/_/download/contextbatch/js/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&locale=en&slack-enabled=true&whisper-enabled=true","startTime":299.5,"connectEnd":299.5,"connectStart":299.5,"domainLookupEnd":299.5,"domainLookupStart":299.5,"fetchStart":299.5,"redirectEnd":0,"redirectStart":0,"requestStart":299.5,"responseEnd":802.3999998569489,"responseStart":802.3999998569489,"secureConnectionStart":299.5},{"duration":506.7000000476837,"initiatorType":"script","name":"https://jira.mariadb.org/s/a9324d6758d385eb45c462685ad88f1d-CDN/lu2cib/820016/12ta74/c92c0caa9a024ae85b0ebdbed7fb4bd7/_/download/contextbatch/js/atl.global,-_super/batch.js?locale=en","startTime":300,"connectEnd":300,"connectStart":300,"domainLookupEnd":300,"domainLookupStart":300,"fetchStart":300,"redirectEnd":0,"redirectStart":0,"requestStart":300,"responseEnd":806.7000000476837,"responseStart":806.7000000476837,"secureConnectionStart":300},{"duration":507,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-en/jira.webresources:calendar-en.js","startTime":300.09999990463257,"connectEnd":300.09999990463257,"connectStart":300.09999990463257,"domainLookupEnd":300.09999990463257,"domainLookupStart":300.09999990463257,"fetchStart":300.09999990463257,"redirectEnd":0,"redirectStart":0,"requestStart":300.09999990463257,"responseEnd":807.0999999046326,"responseStart":807.0999999046326,"secureConnectionStart":300.09999990463257},{"duration":507.09999990463257,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-localisation-moment/jira.webresources:calendar-localisation-moment.js","startTime":300.2999999523163,"connectEnd":300.2999999523163,"connectStart":300.2999999523163,"domainLookupEnd":300.2999999523163,"domainLookupStart":300.2999999523163,"fetchStart":300.2999999523163,"redirectEnd":0,"redirectStart":0,"requestStart":300.2999999523163,"responseEnd":807.3999998569489,"responseStart":807.3999998569489,"secureConnectionStart":300.2999999523163},{"duration":596.2999999523163,"initiatorType":"link","name":"https://jira.mariadb.org/s/b04b06a02d1959df322d9cded3aeecc1-CDN/lu2cib/820016/12ta74/a2ff6aa845ffc9a1d22fe23d9ee791fc/_/download/contextbatch/css/jira.global.look-and-feel,-_super/batch.css","startTime":300.7000000476837,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":300.7000000476837,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":897,"responseStart":0,"secureConnectionStart":0},{"duration":596.3000001907349,"initiatorType":"link","name":"https://jira.mariadb.org/s/3ac36323ba5e4eb0af2aa7ac7211b4bb-CDN/lu2cib/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/css/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.css?jira.create.linked.issue=true","startTime":300.89999985694885,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":300.89999985694885,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":897.2000000476837,"responseStart":0,"secureConnectionStart":0},{"duration":507,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":300.89999985694885,"connectEnd":300.89999985694885,"connectStart":300.89999985694885,"domainLookupEnd":300.89999985694885,"domainLookupStart":300.89999985694885,"fetchStart":300.89999985694885,"redirectEnd":0,"redirectStart":0,"requestStart":300.89999985694885,"responseEnd":807.8999998569489,"responseStart":807.8999998569489,"secureConnectionStart":300.89999985694885},{"duration":507.40000009536743,"initiatorType":"script","name":"https://jira.mariadb.org/s/5d5e8fe91fbc506585e83ea3b62ccc4b-CDN/lu2cib/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/js/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.js?jira.create.linked.issue=true&locale=en","startTime":301.09999990463257,"connectEnd":301.09999990463257,"connectStart":301.09999990463257,"domainLookupEnd":301.09999990463257,"domainLookupStart":301.09999990463257,"fetchStart":301.09999990463257,"redirectEnd":0,"redirectStart":0,"requestStart":301.09999990463257,"responseEnd":808.5,"responseStart":808.5,"secureConnectionStart":301.09999990463257},{"duration":1253.2999999523163,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-js/jira.webresources:bigpipe-js.js","startTime":302.09999990463257,"connectEnd":302.09999990463257,"connectStart":302.09999990463257,"domainLookupEnd":302.09999990463257,"domainLookupStart":302.09999990463257,"fetchStart":302.09999990463257,"redirectEnd":0,"redirectStart":0,"requestStart":302.09999990463257,"responseEnd":1555.3999998569489,"responseStart":1555.3999998569489,"secureConnectionStart":302.09999990463257},{"duration":1470.1999998092651,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-init/jira.webresources:bigpipe-init.js","startTime":307.2000000476837,"connectEnd":307.2000000476837,"connectStart":307.2000000476837,"domainLookupEnd":307.2000000476837,"domainLookupStart":307.2000000476837,"fetchStart":307.2000000476837,"redirectEnd":0,"redirectStart":0,"requestStart":307.2000000476837,"responseEnd":1777.3999998569489,"responseStart":1777.3999998569489,"secureConnectionStart":307.2000000476837},{"duration":647.0999999046326,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":909,"connectEnd":909,"connectStart":909,"domainLookupEnd":909,"domainLookupStart":909,"fetchStart":909,"redirectEnd":0,"redirectStart":0,"requestStart":909,"responseEnd":1556.0999999046326,"responseStart":1556.0999999046326,"secureConnectionStart":909},{"duration":671.1000001430511,"initiatorType":"script","name":"https://www.google-analytics.com/analytics.js","startTime":1210.3999998569489,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":1210.3999998569489,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":1881.5,"responseStart":0,"secureConnectionStart":0}],"fetchStart":0,"domainLookupStart":0,"domainLookupEnd":0,"connectStart":0,"connectEnd":0,"requestStart":112,"responseStart":291,"responseEnd":302,"domLoading":294,"domInteractive":1824,"domContentLoadedEventStart":1824,"domContentLoadedEventEnd":1881,"domComplete":2560,"loadEventStart":2560,"loadEventEnd":2560,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":1779.2000000476837},{"name":"bigPipe.sidebar-id.end","time":1780.0999999046326},{"name":"bigPipe.activity-panel-pipe-id.start","time":1780.2999999523163},{"name":"bigPipe.activity-panel-pipe-id.end","time":1785.3999998569489},{"name":"activityTabFullyLoaded","time":1900.8999998569489}],"measures":[],"correlationId":"24a78634393079","effectiveType":"4g","downlink":10,"rtt":0,"serverDuration":113,"dbReadsTimeInMs":12,"dbConnsTimeInMs":21,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}
draft
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -31,7 +31,7 @@ ENDIF()
# in RPM's:
#set(CPACK_RPM_SPEC_MORE_DEFINE "%define __spec_install_post /bin/true")
-FOREACH(p CMP0022 CMP0046 CMP0040 CMP0048 CMP0054 CMP0067 CMP0074 CMP0075 CMP0069 CMP0135)
+FOREACH(p CMP0022 CMP0046 CMP0040 CMP0048 CMP0054 CMP0056 CMP0066 CMP0067 CMP0074 CMP0075 CMP0069 CMP0135)
IF(POLICY ${p})
CMAKE_POLICY(SET ${p} NEW)
ENDIF()
@@ -246,7 +246,7 @@ ENDIF()
OPTION(WITH_MSAN "Enable memory sanitizer" OFF)
IF (WITH_MSAN)
- MY_CHECK_AND_SET_COMPILER_FLAG("-fsanitize=memory -fsanitize-memory-track-origins -U_FORTIFY_SOURCE" DEBUG RELWITHDEBINFO)
+ MY_CHECK_AND_SET_COMPILER_FLAG("-fsanitize=memory -fsanitize-memory-track-origins -U_FORTIFY_SOURCE")
IF(NOT (have_C__fsanitize_memory__fsanitize_memory_track_origins__U_FORTIFY_SOURCE
AND have_CXX__fsanitize_memory__fsanitize_memory_track_origins__U_FORTIFY_SOURCE))
MESSAGE(FATAL_ERROR "Compiler doesn't support -fsanitize=memory flags")
@@ -256,7 +256,7 @@ IF (WITH_MSAN)
MESSAGE(FATAL_ERROR "C++ Compiler requires support for -stdlib=libc++")
ENDIF()
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++")
- MY_CHECK_AND_SET_LINKER_FLAG("-fsanitize=memory" DEBUG RELWITHDEBINFO)
+ MY_CHECK_AND_SET_LINKER_FLAG("-fsanitize=memory")
IF(NOT HAVE_LINK_FLAG__fsanitize_memory)
MESSAGE(FATAL_ERROR "Linker doesn't support -fsanitize=memory flags")
ENDIF()
Policies use compile and linker flags for checks.
Removing DEBUG/RELWITHDEBINFO allows the CMAKE_C/CXX_FLAGS to be set which is the one used in try_compile etc tests.
Was important with MSAN as libfmt try_run test was failing to link and therefore fail.
experiments with CMAKE_REQUIRED_FLAGS reveiled the following missing/save/restore
diff --git a/cmake/os/SunOS.cmake b/cmake/os/SunOS.cmake
index 3a9d2dccb87..842111e774b 100644
--- a/cmake/os/SunOS.cmake
+++ b/cmake/os/SunOS.cmake
@@ -83,9 +83,10 @@ IF(CMAKE_COMPILER_IS_GNUCC AND CMAKE_SIZEOF_VOID_P EQUAL 4
} ")
CHECK_C_SOURCE_COMPILES(${SOURCE} HAVE_SPARC32_TICK)
IF(NOT HAVE_SPARC32_TICK)
+ SET(SAVE_CMAKE_REQUIRED_FLAGS "${CMAKE_REQUIRED_FLAGS}")
SET(CMAKE_REQUIRED_FLAGS "-mcpu=v9")
CHECK_C_SOURCE_COMPILES(${SOURCE} HAVE_SPARC32_TICK_WITH_V9)
- SET(CMAKE_REQUIRED_FLAGS)
+ SET(CMAKE_REQUIRED_FLAGS "${SAVE_CMAKE_REQUIRED_FLAGS}")
IF(HAVE_SPARC32_TICK_WITH_V9)
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mcpu=v9")
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -mcpu=v9")
diff --git a/configure.cmake b/configure.cmake
index 027a810ed0e..7b484fdc105 100644
--- a/configure.cmake
+++ b/configure.cmake
@@ -273,6 +273,7 @@ FUNCTION(MY_CHECK_PTHREAD_ONCE_INIT)
IF(NOT have_C__Werror)
RETURN()
ENDIF()
+ SET(SAVE_CMAKE_REQUIRED_FLAGS "${CMAKE_REQUIRED_FLAGS}")
SET(CMAKE_REQUIRED_FLAGS "${CMAKE_REQUIRED_FLAGS} -Werror")
CHECK_C_SOURCE_COMPILES("
#include <pthread.h>
@@ -299,6 +300,7 @@ FUNCTION(MY_CHECK_PTHREAD_ONCE_INIT)
HAVE_ARRAY_PTHREAD_ONCE_INIT
)
ENDIF()
+ SET(CMAKE_REQUIRED_FLAGS "${SAVE_CMAKE_REQUIRED_FLAGS}")
IF(HAVE_PTHREAD_ONCE_INIT)
SET(PTHREAD_ONCE_INITIALIZER "PTHREAD_ONCE_INIT" PARENT_SCOPE)
ENDIF()
And
diff --git a/plugin/auth_pam/CMakeLists.txt b/plugin/auth_pam/CMakeLists.txt
index f2cce80f800..04f9111ac54 100644
--- a/plugin/auth_pam/CMakeLists.txt
+++ b/plugin/auth_pam/CMakeLists.txt
@@ -13,6 +13,7 @@ CHECK_FUNCTION_EXISTS (getgrouplist HAVE_GETGROUPLIST)
INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR})
# Check whether getgrouplist uses gtid_t for second and third arguments.
+SET(CMAKE_REQUIRED_FLAGS "${SAVE_CMAKE_REQUIRED_FLAGS}")
SET(CMAKE_REQUIRED_FLAGS -Werror)
CHECK_C_SOURCE_COMPILES(
"
@@ -28,7 +29,7 @@ int main() {
"
HAVE_POSIX_GETGROUPLIST
)
-SET(CMAKE_REQUIRED_FLAGS)
+SET(CMAKE_REQUIRED_FLAGS "${SAVE_CMAKE_REQUIRED_FLAGS}")
SET(CMAKE_REQUIRED_LIBRARIES pam)
CHECK_FUNCTION_EXISTS(pam_syslog HAVE_PAM_SYSLOG)
diff --git a/storage/rocksdb/build_rocksdb.cmake b/storage/rocksdb/build_rocksdb.cmake
index e89dbfc0627..03a7a3052d6 100644
--- a/storage/rocksdb/build_rocksdb.cmake
+++ b/storage/rocksdb/build_rocksdb.cmake
@@ -459,7 +459,8 @@ if(MSVC)
# Workaround Win8.1 SDK bug, that breaks /permissive-
string(REPLACE "/permissive-" "" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}")
else()
- set(CMAKE_REQUIRED_FLAGS "-msse4.2 -mpclmul ${CXX11_FLAGS}")
+ SET(SAVE_CMAKE_REQUIRED_FLAGS "${CMAKE_REQUIRED_FLAGS}")
+ set(CMAKE_REQUIRED_FLAGS "-msse4.2 -mpclmul ${CMAKE_REQUIRED_FLAGS} ${CXX11_FLAGS}")
CHECK_CXX_SOURCE_COMPILES("
#include <cstdint>
@@ -477,7 +478,7 @@ int main() {
set_source_files_properties(${ROCKSDB_SOURCE_DIR}/util/crc32c.cc
PROPERTIES COMPILE_FLAGS "-DHAVE_SSE42 -DHAVE_PCLMUL -msse4.2 -mpclmul")
endif()
- unset(CMAKE_REQUIRED_FLAGS)
+ SET(CMAKE_REQUIRED_FLAGS "${SAVE_CMAKE_REQUIRED_FLAGS}")
endif()
IF(CMAKE_VERSION VERSION_GREATER "2.8.10")
Though these are lower level and not parent_scope.