[FFmpeg-devel] [PATCH] Fix big/little endian check in configure (broken on Mac OS X)

Patrice Bensoussan patrice.bensoussan
Thu Mar 13 23:28:00 CET 2008


Hello,

It seems the endian check in configure has been broken on Mac OS X (tr  
doesn't seem to like binary files). Here is a fix which should  
hopefully work everywhere...

Patrice

Index: configure
===================================================================
--- configure   (revision 12435)
+++ configure   (working copy)
@@ -1563,9 +1563,9 @@
  # ---
  # big/little-endian test
  check_cc <<EOF || die "endian test failed"
-unsigned int endian = 'B' << 24 | 'I' << 16 | 'G' << 8 | 'E';
+unsigned int endian = 'B' << 24 | 'I' << 16 | 'G' << 8;
  EOF
-tr -c -d BIGE < $TMPO | grep -q BIGE && enable bigendian
+strings -n 3 $TMPO | grep -q BIG && enable bigendian

  # ---
  # check availability of some header files





More information about the ffmpeg-devel mailing list