diff options
author | 2012-08-23 22:54:43 +0000 | |
---|---|---|
committer | 2012-08-23 22:54:43 +0000 | |
commit | f75f5c06d64d5b8b773d007b4d3a57ddb5748f7d (patch) | |
tree | da627a79d2b8568a07cb304762d9947dd159b5b3 | |
parent | copy cflags override code from newer unbound's configure.ac to ldns's (diff) | |
download | wireguard-openbsd-f75f5c06d64d5b8b773d007b4d3a57ddb5748f7d.tar.xz wireguard-openbsd-f75f5c06d64d5b8b773d007b4d3a57ddb5748f7d.zip |
regen
-rw-r--r-- | usr.sbin/unbound/ldns/configure | 67 |
1 files changed, 65 insertions, 2 deletions
diff --git a/usr.sbin/unbound/ldns/configure b/usr.sbin/unbound/ldns/configure index 5155759fdcc..d6b58815124 100644 --- a/usr.sbin/unbound/ldns/configure +++ b/usr.sbin/unbound/ldns/configure @@ -4684,8 +4684,71 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu -dnlACX_CHECK_COMPILER_FLAG(g, CFLAGS="-g $CFLAGS") -dnlACX_CHECK_COMPILER_FLAG(O2, CFLAGS="-O2 $CFLAGS") +# allow user to override the -g -O2 flags. +if test "x$CFLAGS" = "x" ; then + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -g" >&5 +$as_echo_n "checking whether $CC supports -g... " >&6; } +cache=`echo g | sed 'y%.=/+-%___p_%'` +if eval \${cv_prog_cc_flag_$cache+:} false; then : + $as_echo_n "(cached) " >&6 +else + +echo 'void f(){}' >conftest.c +if test -z "`$CC $CPPFLAGS $CFLAGS -g -c conftest.c 2>&1`"; then +eval "cv_prog_cc_flag_$cache=yes" +else +eval "cv_prog_cc_flag_$cache=no" +fi +rm -f conftest conftest.o conftest.c + +fi + +if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +: +CFLAGS="$CFLAGS -g" +else +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +: + +fi + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -O2" >&5 +$as_echo_n "checking whether $CC supports -O2... " >&6; } +cache=`echo O2 | sed 'y%.=/+-%___p_%'` +if eval \${cv_prog_cc_flag_$cache+:} false; then : + $as_echo_n "(cached) " >&6 +else + +echo 'void f(){}' >conftest.c +if test -z "`$CC $CPPFLAGS $CFLAGS -O2 -c conftest.c 2>&1`"; then +eval "cv_prog_cc_flag_$cache=yes" +else +eval "cv_prog_cc_flag_$cache=no" +fi +rm -f conftest conftest.o conftest.c + +fi + +if eval "test \"`echo '$cv_prog_cc_flag_'$cache`\" = yes"; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } +: +CFLAGS="$CFLAGS -O2" +else +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +: + +fi + +fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wall" >&5 |