Fix 2 issues in proxendian.h, see details:

Only some OSes include endian.h from sys/types.h, not Termux, so let's include endian.h directly.
Moreover the past logic defined BYTE_ORDER to an undef macro, so BYTE_ORDER was not undef but def to 0
and BYTE_ORDER != LITTLE_ENDIAN && BYTE_ORDER != BIG_ENDIAN was always false as (0!=0 && 0!=0)
This commit is contained in:
Philippe Teuwen 2020-05-13 02:09:03 +02:00
commit 2c4eda6ab9
2 changed files with 16 additions and 13 deletions

View file

@ -51,8 +51,6 @@ DEFCFLAGS += -Wbad-function-cast -Wredundant-decls -Wmissing-prototypes -Wchar-s
# Some more warnings we need first to eliminate, so temporarely tolerated:
DEFCFLAGS += -Wcast-align -Wno-error=cast-align
DEFCFLAGS += -Wswitch-enum -Wno-error=switch-enum
# Termux on-device __BYTE_ORDER and __LITTLE_ENDIAN undef in src/proxendian.h, see #730
DEFCFLAGS += -Wno-error=undef
ifeq ($(platform),Darwin)
# their readline has strict-prototype issues