[gegl] Fix a bug where MMX was not used when SSE was unavailable



commit 546d72c60323f166a39a1d566166f4982acaf38c
Author: Mukund Sivaraman <muks banu com>
Date:   Wed Jul 28 13:33:35 2010 +0530

    Fix a bug where MMX was not used when SSE was unavailable

 configure.ac |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index 1cea442..e675903 100644
--- a/configure.ac
+++ b/configure.ac
@@ -354,12 +354,12 @@ if test "x$enable_mmx" = "xyes"; then
     AC_MSG_RESULT(yes)
 
     if test "x$enable_sse" = "xyes"; then
-      AS_COMPILER_FLAG([-msse], [SSE_EXTRA_CFLAGS_X="-msse"])
-      SSE_EXTRA_CFLAGS="$MMX_EXTRA_CFLAGS $SSE_EXTRA_CFLAGS_X"
+      AS_COMPILER_FLAG([-msse], [SSE_EXTRA_CFLAGS="-msse"])
 
       AC_MSG_CHECKING(whether we can compile SSE code)
 
-      CFLAGS="$CFLAGS $SSE_EXTRA_CFLAGS_X"
+      sse_save_CFLAGS="$CFLAGS"
+      CFLAGS="$sse_save_CFLAGS $SSE_EXTRA_CFLAGS"
 
       AC_COMPILE_IFELSE([asm ("movntps %xmm0, 0");],
         AC_DEFINE(USE_SSE, 1, [Define to 1 if SSE assembly is available.])
@@ -370,6 +370,7 @@ if test "x$enable_mmx" = "xyes"; then
         AC_MSG_WARN([The assembler does not support the SSE command set.])
       )
 
+      CFLAGS="$sse_save_CFLAGS"
     fi
   ,
     enable_mmx=no
@@ -383,7 +384,7 @@ if test "x$enable_mmx" = "xyes"; then
   AC_SUBST(SSE_EXTRA_CFLAGS)
 fi
 
-CFLAGS="$CFLAGS $SSE_EXTRA_CFLAGS"
+CFLAGS="$CFLAGS $MMX_EXTRA_CFLAGS $SSE_EXTRA_CFLAGS"
 
 
 ###############################



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]