summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDarren Tucker <dtucker@zip.com.au>2008-06-16 02:27:48 +1000
committerDarren Tucker <dtucker@zip.com.au>2008-06-16 02:27:48 +1000
commit330c93f68a8cbbf416b2e2c9150e0a9b8964a51b (patch)
tree6d97e9e106aea2c7e9e765e992a40366d37c2c40
parent8b7ab960df02da128c56283ce14b78227ac2d200 (diff)
- (dtucker) [configure.ac] Enable -fno-builtin-memset when using gcc.
-rw-r--r--ChangeLog5
-rw-r--r--configure.ac16
2 files changed, 18 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 0bd06cd6a..38fb74a44 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,6 @@
120080615
2 - (dtucker) [configure.ac] Enable -fno-builtin-memset when using gcc.
3
120080614 420080614
2 - (djm) [openbsd-compat/sigact.c] Avoid NULL derefs in ancient sigaction 5 - (djm) [openbsd-compat/sigact.c] Avoid NULL derefs in ancient sigaction
3 replacement code; patch from ighighi AT gmail.com in bz#1240; 6 replacement code; patch from ighighi AT gmail.com in bz#1240;
@@ -4369,4 +4372,4 @@
4369 OpenServer 6 and add osr5bigcrypt support so when someone migrates 4372 OpenServer 6 and add osr5bigcrypt support so when someone migrates
4370 passwords between UnixWare and OpenServer they will still work. OK dtucker@ 4373 passwords between UnixWare and OpenServer they will still work. OK dtucker@
4371 4374
4372$Id: ChangeLog,v 1.5011 2008/06/15 00:55:34 djm Exp $ 4375$Id: ChangeLog,v 1.5012 2008/06/15 16:27:48 dtucker Exp $
diff --git a/configure.ac b/configure.ac
index aea6cb312..eb71a879a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,4 +1,4 @@
1# $Id: configure.ac,v 1.405 2008/06/13 23:14:46 dtucker Exp $ 1# $Id: configure.ac,v 1.406 2008/06/15 16:27:48 dtucker Exp $
2# 2#
3# Copyright (c) 1999-2004 Damien Miller 3# Copyright (c) 1999-2004 Damien Miller
4# 4#
@@ -15,7 +15,7 @@
15# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 15# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
16 16
17AC_INIT(OpenSSH, Portable, openssh-unix-dev@mindrot.org) 17AC_INIT(OpenSSH, Portable, openssh-unix-dev@mindrot.org)
18AC_REVISION($Revision: 1.405 $) 18AC_REVISION($Revision: 1.406 $)
19AC_CONFIG_SRCDIR([ssh.c]) 19AC_CONFIG_SRCDIR([ssh.c])
20 20
21AC_CONFIG_HEADER(config.h) 21AC_CONFIG_HEADER(config.h)
@@ -112,6 +112,18 @@ if test "$GCC" = "yes" || test "$GCC" = "egcs"; then
112 *) ;; 112 *) ;;
113 esac 113 esac
114 114
115 AC_MSG_CHECKING(if $CC accepts -fno-builtin-memset)
116 saved_CFLAGS="$CFLAGS"
117 CFLAGS="$CFLAGS -fno-builtin-memset"
118 AC_LINK_IFELSE( [AC_LANG_SOURCE([[
119#include <string.h>
120int main(void){char b[10]; memset(b, 0, sizeof(b));}
121 ]])],
122 [ AC_MSG_RESULT(yes) ],
123 [ AC_MSG_RESULT(no)
124 CFLAGS="$saved_CFLAGS" ]
125)
126
115 # -fstack-protector-all doesn't always work for some GCC versions 127 # -fstack-protector-all doesn't always work for some GCC versions
116 # and/or platforms, so we test if we can. If it's not supported 128 # and/or platforms, so we test if we can. If it's not supported
117 # on a give platform gcc will emit a warning so we use -Werror. 129 # on a give platform gcc will emit a warning so we use -Werror.