CmakeLists.txt: define WORDS_BIGENDIAN when the CPU is big endian

fixes #184
This commit is contained in:
Thomas Bernard 2020-03-21 00:31:41 +01:00
parent 7c8dafc28c
commit 35cc068275
No known key found for this signature in database
GPG Key ID: 0FF11B67A5C0863C

View File

@ -402,6 +402,9 @@ endif()
# CPU endianness
include(TestBigEndian)
test_big_endian(HOST_BIG_ENDIAN)
if(HOST_BIG_ENDIAN)
add_definitions(-DWORDS_BIGENDIAN)
endif()
# IEEE floating point
set(HAVE_IEEEFP 1)