2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-31 14:35:26 +00:00

3858. [bug] Disable GCC 4.9 "delete null pointer check".

[RT #35968]
This commit is contained in:
Mark Andrews
2014-05-23 11:25:59 +10:00
parent 35711d3c73
commit 603a787083
3 changed files with 59 additions and 8 deletions

View File

@@ -1,3 +1,6 @@
3858. [bug] Disable GCC 4.9 "delete null pointer check".
[RT #35968]
3857. [bug] Make it harder for a incorrect NOEDNS classification
to be made. [RT #36020]

41
configure vendored
View File

@@ -16707,9 +16707,10 @@ MKDEPCFLAGS="-M"
IRIX_DNSSEC_WARNINGS_HACK=""
if test "X$GCC" = "Xyes"; then
STD_CWARNINGS="$STD_CWARNINGS -W -Wall -Wmissing-prototypes -Wcast-qual -Wwrite-strings -Wformat -Wpointer-arith"
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if \"$CC\" supports -fno-strict-aliasing" >&5
$as_echo_n "checking if \"$CC\" supports -fno-strict-aliasing... " >&6; }
SAVE_CFLAGS=$CFLAGS
SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -fno-strict-aliasing"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
@@ -16728,15 +16729,47 @@ else
FNOSTRICTALIASING=no
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
CFLAGS=$SAVE_CFLAGS
CFLAGS="$SAVE_CFLAGS"
if test "$FNOSTRICTALIASING" = "yes"; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
$as_echo "yes" >&6; }
STD_CWARNINGS="$STD_CWARNINGS -W -Wall -Wmissing-prototypes -Wcast-qual -Wwrite-strings -Wformat -Wpointer-arith -fno-strict-aliasing"
STD_CWARNINGS="$STD_CWARNINGS -fno-strict-aliasing"
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
fi
#
# turn off delete null pointer checks
#
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if \"$CC\" supports -fno-delete-null-pointer-checks" >&5
$as_echo_n "checking if \"$CC\" supports -fno-delete-null-pointer-checks... " >&6; }
SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -fno-delete-null-pointer-checks"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int
main ()
{
;
return 0;
}
_ACEOF
if ac_fn_c_try_compile "$LINENO"; then :
FNODELETENULLPOINTERCHECKS=yes
else
FNODELETENULLPOINTERCHECKS=no
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
CFLAGS="$SAVE_CFLAGS"
if test "$FNODELETENULLPOINTERCHECKS" = "yes"; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
$as_echo "yes" >&6; }
STD_CWARNINGS="$STD_CWARNINGS -fno-delete-null-pointer-checks"
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
STD_CWARNINGS="$STD_CWARNINGS -W -Wall -Wmissing-prototypes -Wcast-qual -Wwrite-strings -Wformat -Wpointer-arith"
fi
case "$host" in
*-hp-hpux*)

View File

@@ -2209,17 +2209,32 @@ MKDEPCFLAGS="-M"
IRIX_DNSSEC_WARNINGS_HACK=""
if test "X$GCC" = "Xyes"; then
STD_CWARNINGS="$STD_CWARNINGS -W -Wall -Wmissing-prototypes -Wcast-qual -Wwrite-strings -Wformat -Wpointer-arith"
AC_MSG_CHECKING(if "$CC" supports -fno-strict-aliasing)
SAVE_CFLAGS=$CFLAGS
SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -fno-strict-aliasing"
AC_TRY_COMPILE(,, [FNOSTRICTALIASING=yes],[FNOSTRICTALIASING=no])
CFLAGS=$SAVE_CFLAGS
CFLAGS="$SAVE_CFLAGS"
if test "$FNOSTRICTALIASING" = "yes"; then
AC_MSG_RESULT(yes)
STD_CWARNINGS="$STD_CWARNINGS -W -Wall -Wmissing-prototypes -Wcast-qual -Wwrite-strings -Wformat -Wpointer-arith -fno-strict-aliasing"
STD_CWARNINGS="$STD_CWARNINGS -fno-strict-aliasing"
else
AC_MSG_RESULT(no)
fi
#
# turn off delete null pointer checks
#
AC_MSG_CHECKING(if "$CC" supports -fno-delete-null-pointer-checks)
SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -fno-delete-null-pointer-checks"
AC_TRY_COMPILE(,, [FNODELETENULLPOINTERCHECKS=yes],
[FNODELETENULLPOINTERCHECKS=no])
CFLAGS="$SAVE_CFLAGS"
if test "$FNODELETENULLPOINTERCHECKS" = "yes"; then
AC_MSG_RESULT(yes)
STD_CWARNINGS="$STD_CWARNINGS -fno-delete-null-pointer-checks"
else
AC_MSG_RESULT(no)
STD_CWARNINGS="$STD_CWARNINGS -W -Wall -Wmissing-prototypes -Wcast-qual -Wwrite-strings -Wformat -Wpointer-arith"
fi
case "$host" in
*-hp-hpux*)