blob: bdc2c58c26931e859f037cde2ada3e8ba3f705fc (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
--- pixz-1.0.6.orig/src/endian.c
+++ pixz-1.0.6/src/endian.c
@@ -19,19 +19,19 @@
#include <sys/endian.h>
#endif
-#if !HAVE_DECL_HTOLE64
+#if !HAVE_DECL_HTOLE64 && !defined(htole64)
# if __BYTE_ORDER == __LITTLE_ENDIAN
# define htole64(x) (x)
# else
-# define htole64(x) __bswap_64 (x)
+# define htole64(x) __bswap64 (x)
# endif
#endif
-#if !HAVE_DECL_LE64TOH
+#if !HAVE_DECL_LE64TOH && !defined(le64toh)
# if __BYTE_ORDER == __LITTLE_ENDIAN
# define le64toh(x) (x)
# else
-# define le64toh(x) __bswap_64 (x)
+# define le64toh(x) __bswap64 (x)
# endif
#endif
|