Lines 961-974
Link Here
|
961 |
# skip endianness check for Intel Compiler and MSVS, as all supported platforms are little. each have flags that will cause the check to fail as well |
961 |
# skip endianness check for Intel Compiler and MSVS, as all supported platforms are little. each have flags that will cause the check to fail as well |
962 |
CPU_ENDIAN="little-endian" |
962 |
CPU_ENDIAN="little-endian" |
963 |
if [ $compiler = GNU ]; then |
963 |
if [ $compiler = GNU ]; then |
964 |
echo "int i[2] = {0x42494745,0}; double f[2] = {0x1.0656e6469616ep+102,0};" > conftest.c |
964 |
cat <<-EOF > conftest.c |
965 |
$CC $CFLAGS conftest.c -c -o conftest.o 2>/dev/null || die "endian test failed" |
965 |
#include <stdint.h> |
966 |
if (${cross_prefix}strings -a conftest.o | grep -q BIGE) && (${cross_prefix}strings -a conftest.o | grep -q FPendian) ; then |
966 |
#define IS_BIG_ENDIAN (*(uint16_t *)"\0\xff" < 0x100) |
967 |
define WORDS_BIGENDIAN |
967 |
int main(void) { return IS_BIG_ENDIAN; } |
968 |
CPU_ENDIAN="big-endian" |
968 |
EOF |
969 |
elif !(${cross_prefix}strings -a conftest.o | grep -q EGIB && ${cross_prefix}strings -a conftest.o | grep -q naidnePF) ; then |
969 |
$CC $CFLAGS -o conftest conftest.c || die "endian test failed" |
970 |
die "endian test failed" |
970 |
./conftest || { |
971 |
fi |
971 |
define WORDS_BIGENDIAN |
|
|
972 |
CPU_ENDIAN="big-endian" |
973 |
} |
972 |
fi |
974 |
fi |
973 |
|
975 |
|
974 |
if [ "$cli_libx264" = "system" -a "$shared" != "yes" ] ; then |
976 |
if [ "$cli_libx264" = "system" -a "$shared" != "yes" ] ; then |