disable sse3 if immintrin.h not found.
authorraster <raster@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Wed, 7 Dec 2011 00:10:36 +0000 (00:10 +0000)
committerraster <raster@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Wed, 7 Dec 2011 00:10:36 +0000 (00:10 +0000)
git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/evas@65980 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

ChangeLog
configure.ac

index a331469..1a30a4c 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
         and monitor GL state etc. and get it right sharing state with
         evas without having to rely specifically on a new GL context.
 
+2011-12-07 Carsten Haitzler (The Rasterman)
+
+        * Fix build if gcc too old - if immintrin.h doesn't exist,
+        don't enable SSE3.
+
index 670564e..1eb82f9 100644 (file)
@@ -1271,9 +1271,16 @@ AC_ARG_ENABLE(cpu-sse3,
   AS_HELP_STRING([--enable-cpu-sse3], [enable sse3 code]),
   [
       if test "x$enableval" = "xyes" ; then
-        AC_MSG_RESULT(yes)
-        AC_DEFINE(BUILD_SSE3, 1, [Build SSE3 Code])
-        build_cpu_sse3="yes"
+        AC_CHECK_HEADER(immintrin.h,
+          [
+            AC_MSG_RESULT(yes)
+            AC_DEFINE(BUILD_SSE3, 1, [Build SSE3 Code])
+            build_cpu_sse3="yes"
+           ],
+          [
+            AC_MSG_RESULT(no)
+            build_cpu_sse3="no"
+          ])
       else
         AC_MSG_RESULT(no)
         build_cpu_sse3="no"
@@ -1282,7 +1289,16 @@ AC_ARG_ENABLE(cpu-sse3,
   [
     AC_MSG_RESULT($build_cpu_sse3)
     if test "x$build_cpu_sse3" = "xyes" ; then
-      AC_DEFINE(BUILD_SSE3, 1, [Build SSE3 Code])
+      AC_CHECK_HEADER(immintrin.h,
+        [
+          AC_MSG_RESULT(yes)
+          AC_DEFINE(BUILD_SSE3, 1, [Build SSE3 Code])
+          build_cpu_sse3="yes"
+         ],
+        [
+          AC_MSG_RESULT(no)
+          build_cpu_sse3="no"
+        ])
     fi
   ]
 )