common/m4/gst-arch.m4: Implmenent a whitelist and blacklist for GST_UNALIGNED_ACESS...
authorDavid Schleef <ds@schleef.org>
Fri, 16 Apr 2004 23:53:19 +0000 (23:53 +0000)
committerDavid Schleef <ds@schleef.org>
Fri, 16 Apr 2004 23:53:19 +0000 (23:53 +0000)
Original commit message from CVS:
* common/m4/gst-arch.m4:  Implmenent a whitelist and blacklist
for GST_UNALIGNED_ACESS, since we essentially know which archs
are ok.

m4/gst-arch.m4

index 13b18e4..b304f3e 100644 (file)
@@ -85,6 +85,20 @@ AM_CONDITIONAL(HAVE_LIBMMX,         test "x$USE_LIBMMX" = "xyes")
 AC_DEFUN([GST_UNALIGNED_ACCESS], [
   AC_MSG_CHECKING([if unaligned memory access works correctly])
   if test x"$as_cv_unaligned_access" = x ; then
+    case $host in
+      alpha*|arm*|hp*|mips*|sh*|sparc*|ia64*)
+        _AS_ECHO_N([(blacklisted) ])
+        as_cv_unaligned_access=no
+       ;;
+      i?86*|powerpc*|m68k*)
+        _AS_ECHO_N([(whitelisted) ])
+        as_cv_unaligned_access=yes
+       ;;
+    esac
+  else
+    _AS_ECHO_N([(cached) ])
+  fi
+  if test x"$as_cv_unaligned_access" = x ; then
     AC_TRY_RUN([
 int main(int argc, char **argv)
 {