diff --git a/configure.in b/configure.in index 0e3184f957..96a9d16796 100644 --- a/configure.in +++ b/configure.in @@ -333,6 +333,13 @@ AC_ARG_ENABLE(debug, esac]) AC_SUBST(PROD_BUILD_FLG) +dnl Avoid dumb '-g -O2' autoconf's default +dnl Debugging information and optimization flags should be set in prefix.$platform file +dnl Should be replaced with AC_PROG_GCC_DEFAULT_FLAGS() when available +if test "$CFLAGS" = "-g -O2" -o "$CFLAGS" = "-g" -o "$CFLAGS" = "-O2"; then + CFLAGS= +fi + dnl Find out how to use threads on this platform pre_acx_pthread_cflags=$CFLAGS ACX_PTHREAD([