diff options
author | Brad King <brad.king@kitware.com> | 2018-04-25 12:52:53 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2018-04-25 12:53:01 (GMT) |
commit | 8fd76452a46b89450a1d3a5d5eb5c96541dc20a1 (patch) | |
tree | 0ddc10c0880f0253a1e609e2a79550f8bbc49fdc | |
parent | 52c11e4f646404ea75e013c358196f64cb1a925e (diff) | |
parent | 7b1c5f9f05bb8f3b48a5284cc236f1b483b70cf9 (diff) | |
download | CMake-8fd76452a46b89450a1d3a5d5eb5c96541dc20a1.zip CMake-8fd76452a46b89450a1d3a5d5eb5c96541dc20a1.tar.gz CMake-8fd76452a46b89450a1d3a5d5eb5c96541dc20a1.tar.bz2 |
Merge topic 'testbigendian-cache-check-fix'
7b1c5f9f05 TestBigEndian: Include CheckTypeSize outside macro
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1999
-rw-r--r-- | Modules/TestBigEndian.cmake | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Modules/TestBigEndian.cmake b/Modules/TestBigEndian.cmake index cc627d0..9a4bce5 100644 --- a/Modules/TestBigEndian.cmake +++ b/Modules/TestBigEndian.cmake @@ -14,6 +14,8 @@ # TEST_BIG_ENDIAN(VARIABLE) # VARIABLE - variable to store the result to +include(CheckTypeSize) + macro(TEST_BIG_ENDIAN VARIABLE) if(NOT DEFINED HAVE_${VARIABLE}) message(STATUS "Check if the system is big endian") @@ -27,8 +29,6 @@ macro(TEST_BIG_ENDIAN VARIABLE) message(FATAL_ERROR "TEST_BIG_ENDIAN needs either C or CXX language enabled") endif() - include(CheckTypeSize) - CHECK_TYPE_SIZE("unsigned short" CMAKE_SIZEOF_UNSIGNED_SHORT LANGUAGE ${_test_language}) if(CMAKE_SIZEOF_UNSIGNED_SHORT EQUAL 2) message(STATUS "Using unsigned short") |