diff options
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 32 |
1 files changed, 10 insertions, 22 deletions
diff --git a/configure.ac b/configure.ac index 5357cab60..d56bf6d36 100644 --- a/configure.ac +++ b/configure.ac | |||
@@ -1,4 +1,4 @@ | |||
1 | # $Id: configure.ac,v 1.473 2011/05/05 04:44:25 tim Exp $ | 1 | # $Id: configure.ac,v 1.474 2011/05/20 01:45:25 djm Exp $ |
2 | # | 2 | # |
3 | # Copyright (c) 1999-2004 Damien Miller | 3 | # Copyright (c) 1999-2004 Damien Miller |
4 | # | 4 | # |
@@ -15,22 +15,10 @@ | |||
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 | ||
17 | AC_INIT([OpenSSH], [Portable], [openssh-unix-dev@mindrot.org]) | 17 | AC_INIT([OpenSSH], [Portable], [openssh-unix-dev@mindrot.org]) |
18 | AC_REVISION($Revision: 1.473 $) | 18 | AC_REVISION($Revision: 1.474 $) |
19 | AC_CONFIG_SRCDIR([ssh.c]) | 19 | AC_CONFIG_SRCDIR([ssh.c]) |
20 | AC_LANG([C]) | 20 | AC_LANG([C]) |
21 | 21 | ||
22 | # local macros | ||
23 | AC_DEFUN([OPENSSH_CHECK_CFLAG_COMPILE], [{ | ||
24 | AC_MSG_CHECKING([if $CC supports $1]) | ||
25 | saved_CFLAGS="$CFLAGS" | ||
26 | CFLAGS="$CFLAGS $1" | ||
27 | AC_COMPILE_IFELSE([AC_LANG_SOURCE([[void main(void) { return 0; }]])], | ||
28 | [ AC_MSG_RESULT([yes]) ], | ||
29 | [ AC_MSG_RESULT([no]) | ||
30 | CFLAGS="$saved_CFLAGS" ] | ||
31 | ) | ||
32 | }]) | ||
33 | |||
34 | AC_CONFIG_HEADER([config.h]) | 22 | AC_CONFIG_HEADER([config.h]) |
35 | AC_PROG_CC | 23 | AC_PROG_CC |
36 | AC_CANONICAL_HOST | 24 | AC_CANONICAL_HOST |
@@ -128,14 +116,14 @@ AC_ARG_WITH([stackprotect], | |||
128 | 116 | ||
129 | 117 | ||
130 | if test "$GCC" = "yes" || test "$GCC" = "egcs"; then | 118 | if test "$GCC" = "yes" || test "$GCC" = "egcs"; then |
131 | OPENSSH_CHECK_CFLAG_COMPILE([-Wall]) | 119 | OSSH_CHECK_CFLAG_COMPILE([-Wall]) |
132 | OPENSSH_CHECK_CFLAG_COMPILE([-Wpointer-arith]) | 120 | OSSH_CHECK_CFLAG_COMPILE([-Wpointer-arith]) |
133 | OPENSSH_CHECK_CFLAG_COMPILE([-Wuninitialized]) | 121 | OSSH_CHECK_CFLAG_COMPILE([-Wuninitialized]) |
134 | OPENSSH_CHECK_CFLAG_COMPILE([-Wsign-compare]) | 122 | OSSH_CHECK_CFLAG_COMPILE([-Wsign-compare]) |
135 | OPENSSH_CHECK_CFLAG_COMPILE([-Wformat-security]) | 123 | OSSH_CHECK_CFLAG_COMPILE([-Wformat-security]) |
136 | OPENSSH_CHECK_CFLAG_COMPILE([-Wno-pointer-sign]) | 124 | OSSH_CHECK_CFLAG_COMPILE([-Wpointer-sign], [-Wno-pointer-sign]) |
137 | OPENSSH_CHECK_CFLAG_COMPILE([-Wno-unused-result]) | 125 | OSSH_CHECK_CFLAG_COMPILE([-Wunused-result], [-Wno-unused-result]) |
138 | OPENSSH_CHECK_CFLAG_COMPILE([-fno-strict-aliasing]) | 126 | OSSH_CHECK_CFLAG_COMPILE([-fno-strict-aliasing]) |
139 | AC_MSG_CHECKING([gcc version]) | 127 | AC_MSG_CHECKING([gcc version]) |
140 | GCC_VER=`$CC -v 2>&1 | $AWK '/gcc version /{print $3}'` | 128 | GCC_VER=`$CC -v 2>&1 | $AWK '/gcc version /{print $3}'` |
141 | case $GCC_VER in | 129 | case $GCC_VER in |