# HG changeset patch # User Richard Laager # Date 1134075589 0 # Node ID 8c339d9f1bb48112a005803022e72c6bd1a092d2 # Parent bc249de5ea02b349b5634f711146d26a13da9604 [gaim-migrate @ 14718] Use the glib byte order macros, so we can prune out configure.ac a bit. Also, add a warning in case someone tries to compile this on a machine with an unknown byte ordering. I really don't think that'll happen, but it doesn't hurt to be thorough. committer: Tailor Script diff -r bc249de5ea02 -r 8c339d9f1bb4 src/gtksound.c --- a/src/gtksound.c Thu Dec 08 20:59:33 2005 +0000 +++ b/src/gtksound.c Thu Dec 08 20:59:49 2005 +0000 @@ -474,14 +474,16 @@ afSetVirtualSampleFormat(file, AF_DEFAULT_TRACK, AF_SAMPFMT_TWOSCOMP, format.bits); -#if __BYTE_ORDER == __BIG_ENDIAN +#if G_BYTE_ORDER == G_BIG_ENDIAN format.byte_format = AO_FMT_BIG; afSetVirtualByteOrder(file, AF_DEFAULT_TRACK, AF_BYTEORDER_BIGENDIAN); -#elif __BYTE_ORDER == __LITTLE_ENDIAN +#elif G_BYTE_ORDER == G_LITTLE_ENDIAN format.byte_format = AO_FMT_LITTLE; afSetVirtualByteOrder(file, AF_DEFAULT_TRACK, AF_BYTEORDER_LITTLEENDIAN); +#else +#warning Unknown endianness #endif bytes_per_frame = format.bits * format.channels / 8;