compat BUGFIX avoid macro collision
diff --git a/CMakeModules/UseCompat.cmake b/CMakeModules/UseCompat.cmake
index 358271c..34374bb 100644
--- a/CMakeModules/UseCompat.cmake
+++ b/CMakeModules/UseCompat.cmake
@@ -17,7 +17,7 @@
check_symbol_exists(strndup "string.h" HAVE_STRNDUP)
check_symbol_exists(getline "stdio.h" HAVE_GETLINE)
- TEST_BIG_ENDIAN(BIG_ENDIAN)
+ TEST_BIG_ENDIAN(IS_BIG_ENDIAN)
# header and object file
configure_file(${PROJECT_SOURCE_DIR}/compat/compat.h.in ${PROJECT_BINARY_DIR}/compat.h @ONLY)
diff --git a/compat/compat.h.in b/compat/compat.h.in
index 947b0aa..73024f4 100644
--- a/compat/compat.h.in
+++ b/compat/compat.h.in
@@ -53,14 +53,14 @@
#undef le64toh
#undef htole64
-#cmakedefine BIG_ENDIAN
+#cmakedefine IS_BIG_ENDIAN
-#ifdef BIG_ENDIAN
-# define le64toh(x) (x)
-# define htole64(x) (x)
-#else
+#ifdef IS_BIG_ENDIAN
# define le64toh(x) bswap64(x)
# define htole64(x) bswap64(x)
+#else
+# define le64toh(x) (x)
+# define htole64(x) (x)
#endif
#ifndef MAP_ANONYMOUS