diff options
-rw-r--r-- | cmake/scripts/linux/ArchSetup.cmake | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/cmake/scripts/linux/ArchSetup.cmake b/cmake/scripts/linux/ArchSetup.cmake index b68efe3bd0..9343aa1cf4 100644 --- a/cmake/scripts/linux/ArchSetup.cmake +++ b/cmake/scripts/linux/ArchSetup.cmake @@ -130,3 +130,13 @@ endif() if(ENABLE_VDPAU) set(ENABLE_GLX ON CACHE BOOL "Enabling GLX" FORCE) endif() + +# Architecture endianness detector +include(TestBigEndian) +TEST_BIG_ENDIAN(ARCH_IS_BIGENDIAN) +if(ARCH_IS_BIGENDIAN) + message(STATUS "Host architecture is big-endian") + list(APPEND ARCH_DEFINES "-DWORDS_BIGENDIAN=1") +else() + message(STATUS "Host architecture is little-endian") +endif() |