Add -O2 to CFLAGS by default, -O0 if noopt is set.
authorAlessio Treglia <alessio@debian.org>
Sat, 14 Nov 2020 02:27:34 +0000 (21:27 -0500)
committerReinhard Tartler <siretart@tauware.de>
Sat, 14 Nov 2020 02:27:34 +0000 (21:27 -0500)
Forwarded: not-needed

Forwarded: not-needed
Gbp-Pq: Name gcc-optflags.patch

configure

index 485bfe22bf5d877624d5552a319b6e116175909e..adab0caa2a4f64d90dbbc02cb18fc485980fc290 100755 (executable)
--- a/configure
+++ b/configure
@@ -360,7 +360,7 @@ for opt do
             ;;
         --cpu=*) cpu=`echo $opt | cut -d '=' -f 2`
             ;;
-        --enable-debug) debuginfo="yes"; no_gcc_opt="yes"
+        --enable-debug) debuginfo="yes";
             ;;
         --disable-opt) no_gcc_opt="yes"
             ;;
@@ -708,7 +708,7 @@ fi
 
 #GCC opt
 if test "$no_gcc_opt" = "no"; then
-    CFLAGS="-O3 $CFLAGS"
+    CFLAGS="-O2 $CFLAGS"
 else
     CFLAGS="-O0 $CFLAGS"
 fi