mirror of
https://github.com/webmproject/libwebp.git
synced 2025-07-18 23:09:52 +02:00
configure.ac: add AC_C_BIGENDIAN
this defines WORDS_BIGENDIAN, replacing uses of __BIG_ENDIAN__/__BYTE_ORDER__ with it + fixes lossless BGRA output with big-endian toolchains that do not define __BIG_ENDIAN__ (codesourcery mips gcc) Change-Id: Ieaccd623292d235343b5e34b7a720fc251c432d7
This commit is contained in:
@ -70,7 +70,7 @@ static WEBP_INLINE void VP8LoadNewBytes(VP8BitReader* const br) {
|
||||
const lbit_t in_bits = *(const lbit_t*)br->buf_;
|
||||
#endif
|
||||
br->buf_ += BITS >> 3;
|
||||
#if !defined(__BIG_ENDIAN__)
|
||||
#if !defined(WORDS_BIGENDIAN)
|
||||
#if (BITS > 32)
|
||||
bits = BSwap64(in_bits);
|
||||
bits >>= 64 - BITS;
|
||||
@ -83,7 +83,7 @@ static WEBP_INLINE void VP8LoadNewBytes(VP8BitReader* const br) {
|
||||
#else // BITS == 8
|
||||
bits = (bit_t)in_bits;
|
||||
#endif // BITS > 32
|
||||
#else // BIG_ENDIAN
|
||||
#else // WORDS_BIGENDIAN
|
||||
bits = (bit_t)in_bits;
|
||||
if (BITS != 8 * sizeof(bit_t)) bits >>= (8 * sizeof(bit_t) - BITS);
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user