Enable "-O2" always, not just for cross-compiles.
---
Building without optimization creates bloated and slow code.
Plus it hides some kinds of bugs.  Appropriate AFAICT to merge
right away...

 configure.in |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

Enable "-O2" always, not just for cross-compiles.
---
 configure.in |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

--- a/configure.in
+++ b/configure.in
@@ -994,11 +994,13 @@ if test $gcc_warnings = yes; then
   CFLAGS="$CFLAGS $GCC_WARNINGS"
 fi
 
+CFLAGS="$CFLAGS -O2"
+
 # Setup for compiling build tools
 AC_MSG_CHECKING([for a C compiler for build tools])
 if test $cross_compiling = yes; then
   AC_CHECK_PROGS(CC_FOR_BUILD, gcc cc)
-  CFLAGS_FOR_BUILD="-g -O2 $GCC_WARNINGS"
+  CFLAGS_FOR_BUILD="-g $GCC_WARNINGS"
 else
   CC_FOR_BUILD=$CC
   CFLAGS_FOR_BUILD=$CFLAGS
_______________________________________________
Openocd-development mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/openocd-development

Reply via email to