blob: 706906af48af439d3e9986d83fe3acd095451cd9 [file] [log] [blame] [edit]
diff -Naur cereal-1.2.2/include/cereal/archives/json.hpp cereal-1.2.2-patched/include/cereal/archives/json.hpp
--- cereal-1.2.2/include/cereal/archives/json.hpp 2017-02-13 01:06:58.000000000 +0300
+++ cereal-1.2.2-patched/include/cereal/archives/json.hpp 2018-10-23 22:38:05.621656900 +0300
@@ -643,7 +643,7 @@
// Special cases to handle various flavors of long, which tend to conflict with
// the int32_t or int64_t on various compiler/OS combinations. MSVC doesn't need any of this.
- #ifndef _MSC_VER
+ #if not defined(_MSC_VER) && not defined(__MINGW32__)
private:
//! 32 bit signed long loading from current node
template <class T> inline
diff -Naur cereal-1.2.2/unittests/CMakeLists.txt cereal-1.2.2-patched/unittests/CMakeLists.txt
--- cereal-1.2.2/unittests/CMakeLists.txt 2017-02-13 01:06:58.000000000 +0300
+++ cereal-1.2.2-patched/unittests/CMakeLists.txt 2018-10-23 22:45:34.970358200 +0300
@@ -11,7 +11,7 @@
if(NOT SKIP_PORTABILITY_TEST)
# Build the portability test only if we are on a 64-bit machine (void* is 8 bytes)
if((${CMAKE_SIZEOF_VOID_P} EQUAL 8))
- if(NOT MSVC)
+ if(NOT WIN32)
add_executable(portability_test32 portability_test.cpp)
set_target_properties(portability_test32 PROPERTIES COMPILE_FLAGS "-m32")
set_target_properties(portability_test32 PROPERTIES LINK_FLAGS "-m32")
@@ -24,7 +24,7 @@
-DPORTABILITY_TEST_DIR=$<TARGET_FILE_DIR:portability_test64>
-P "${CMAKE_CURRENT_SOURCE_DIR}/run_portability_test.cmake")
- elseif(MSVC)
+ elseif()
add_executable(portability_test32 portability_test.cpp)
endif()
endif()
@@ -45,7 +45,7 @@
add_test("${TEST_TARGET}" "${TEST_TARGET}")
# If we are on a 64-bit machine, create an extra 32-bit version of the test if portability testing is enabled
- if((NOT MSVC) AND (${CMAKE_SIZEOF_VOID_P} EQUAL 8) AND (NOT SKIP_PORTABILITY_TEST))
+ if((NOT WIN32) AND (${CMAKE_SIZEOF_VOID_P} EQUAL 8) AND (NOT SKIP_PORTABILITY_TEST))
add_executable(${TEST_TARGET}_32 ${TEST_SOURCE})
set_target_properties(${TEST_TARGET}_32 PROPERTIES
COMPILE_FLAGS "-m32" LINK_FLAGS "-m32")
@@ -57,7 +57,7 @@
endforeach()
# Add the valgrind target
-if(NOT MSVC)
+if(NOT WIN32)
add_custom_target(valgrind
COMMAND "${CMAKE_CURRENT_SOURCE_DIR}/run_valgrind.sh")
@@ -85,7 +85,7 @@
target_link_libraries(${COVERAGE_TARGET} ${CEREAL_THREAD_LIBS})
endif()
endforeach()
-endif(NOT MSVC)
+endif()
if(NOT CMAKE_VERSION VERSION_LESS 3.0)
add_test(test_cmake_config_module ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_SOURCE_DIR}/cmake-config-module.cmake)
diff -Naur cereal-1.3.0/unittests/boost/CMakeLists.txt cereal-1.3.0-patched/unittests/boost/CMakeLists.txt
--- cereal-1.3.0/unittests/boost/CMakeLists.txt 2020-06-11 01:06:58.000000000 +0300
+++ cereal-1.3.0-patched/unittests/boost/CMakeLists.txt 2020-06-11 22:45:34.970358200 +0300
@@ -12,7 +12,7 @@
add_test("${TEST_TARGET}" "${TEST_TARGET}")
# If we are on a 64-bit machine, create an extra 32-bit version of the test if portability testing is enabled
- if((NOT MSVC) AND (${CMAKE_SIZEOF_VOID_P} EQUAL 8) AND (NOT SKIP_PORTABILITY_TEST))
+ if((NOT WIN32) AND (${CMAKE_SIZEOF_VOID_P} EQUAL 8) AND (NOT SKIP_PORTABILITY_TEST))
add_executable(${TEST_TARGET}_32 ${TEST_SOURCE})
set_target_properties(${TEST_TARGET}_32 PROPERTIES
COMPILE_FLAGS "-m32" LINK_FLAGS "-m32")
@@ -21,7 +21,7 @@
endforeach()
-if(NOT MSVC)
+if(NOT WIN32)
# add tests to coverage
foreach(TEST_SOURCE ${TESTS})
string(REPLACE ".cpp" "" COVERAGE_TARGET "${TEST_SOURCE}")