[xiph-commits] r16054 - trunk/ogg

giles at svn.xiph.org giles at svn.xiph.org
Wed May 27 06:10:39 PDT 2009


Author: giles
Date: 2009-05-27 06:10:39 -0700 (Wed, 27 May 2009)
New Revision: 16054

Modified:
   trunk/ogg/configure.in
Log:
Only pass -mv8 on sparc if the compiler supports it.

Propagated from codec-level configure scripts.


Modified: trunk/ogg/configure.in
===================================================================
--- trunk/ogg/configure.in	2009-05-27 13:09:33 UTC (rev 16053)
+++ trunk/ogg/configure.in	2009-05-27 13:10:39 UTC (rev 16054)
@@ -50,9 +50,18 @@
                 PROFILE="-Wall -W -pg -g -O20 -ffast-math -fsigned-char"
 		;;
         sparc-sun-*)
-                DEBUG="-g -Wall -fsigned-char -mv8"
-                CFLAGS="-O20 -ffast-math -fsigned-char -mv8"
-                PROFILE="-pg -g -O20 -fsigned-char -mv8" 
+                sparc_cpu=""
+                AC_MSG_CHECKING([if gcc supports -mv8])
+                old_cflags="$CFLAGS"
+                CFLAGS="$CFLAGS -mv8"
+                AC_TRY_COMPILE(, [return 0;], [
+                        AC_MSG_RESULT([yes])
+                        sparc_cpu="-mv8"
+                ])
+                CFLAGS="$old_cflags"
+                DEBUG="-g -Wall -fsigned-char $sparc_cpu"
+                CFLAGS="-O20 -ffast-math -fsigned-char $sparc_cpu"
+                PROFILE="-pg -g -O20 -fsigned-char $sparc_cpu" 
 		;;
 	*-*-darwin*)
 		DEBUG="-fno-common -g -Wall -fsigned-char"



More information about the commits mailing list