From b1aebdd7f9e3988d338a10cc608ca3c5221ffa49 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sl=C3=A1vek=20Banko?= Date: Sat, 4 Feb 2017 18:26:31 +0100 Subject: [PATCH] Fix detection whether the system is big endian MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Slávek Banko --- ConfigureChecks.cmake | 3 +++ config.h.cmake | 4 ++++ 2 files changed, 7 insertions(+) diff --git a/ConfigureChecks.cmake b/ConfigureChecks.cmake index 9466c7c..19f34a9 100644 --- a/ConfigureChecks.cmake +++ b/ConfigureChecks.cmake @@ -24,6 +24,9 @@ endif( WITH_GCC_VISIBILITY ) tde_setup_architecture_flags( ) +include(TestBigEndian) +test_big_endian(WORDS_BIGENDIAN) + # Check system configuration check_include_file ( "iconv.h" HAVE_ICONV_H ) check_include_file ( "endian.h" HAVE_ENDIAN_H ) diff --git a/config.h.cmake b/config.h.cmake index 0b361fb..5d10ff6 100644 --- a/config.h.cmake +++ b/config.h.cmake @@ -1,5 +1,9 @@ #cmakedefine VERSION "@VERSION@" +/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most + significant byte first (like Motorola and SPARC, unlike Intel). */ +#cmakedefine WORDS_BIGENDIAN @WORDS_BIGENDIAN@ + // User specified build options #cmakedefine HAVE_K3BSETUP