From 65ee731b75c4fc24b2a73b32cc081704fc0b6063 Mon Sep 17 00:00:00 2001 From: Laurent Bercot Date: Wed, 13 Dec 2023 08:39:23 +0000 Subject: Better endianness detection for Solaris Signed-off-by: Laurent Bercot --- configure | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) (limited to 'configure') diff --git a/configure b/configure index 823899a..db92f46 100755 --- a/configure +++ b/configure @@ -196,7 +196,7 @@ trybasic () { tryendianness () { echo "Checking endianness..." if iscached endianness ; then return ; fi - for i in endian.h sys/endian.h machine/endian.h arpa/nameser_compat.h ; do + for i in endian.h sys/endian.h machine/endian.h ; do cat > "$tmpc" < "$tmpc" < "$tmpc" < +int a = _${k}_ENDIAN ; +EOF + if trybasic "$tmpc" ; then + echo "endianness: $j" >> "$sysdeps/sysdeps" + echo " ... $j" + rm -f "$tmpc" + return + fi + done rm -f "$tmpc" fail "$0: error: unable to determine endianness: no suitable endian.h found" } -- cgit v1.2.3