[rhythmbox] fix check for -O1+ in CFLAGS for -Wuninitialized so autoconf doesn't break it



commit e5f7475d184f622061089e680b447d94c668abf8
Author: Jonathan Matthew <jonathan d14n org>
Date:   Fri Nov 5 11:37:57 2010 +1000

    fix check for -O1+ in CFLAGS for -Wuninitialized so autoconf doesn't break it

 configure.ac |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index a9612e3..ebfa6be 100644
--- a/configure.ac
+++ b/configure.ac
@@ -564,8 +564,8 @@ if test "$GCC" = "yes" -a "$set_more_warnings" != "no"; then
 	-Wcast-align -Wall \
 	-Werror -std=gnu89"
 
-	if echo "$CFLAGS" | grep -e '-O[1-9]'; then
-	   WARN_CFLAGS="-Wuninitialized $WARN_CFLAGS"
+	if echo "$CFLAGS" | grep -q -- '-O' && echo "$CFLAGS" | grep -q -v -- '-O0'; then
+		WARN_CFLAGS="-Wuninitialized $WARN_CFLAGS"
 	fi
 
 	for option in $WARN_CFLAGS; do



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