Re: Call for testing: OpenSSH-6.5

[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

 



On 27/01/14 14:36, Tom G. Christensen wrote:
So this is the real problem:
checking for inttypes.h... no
...
checking for uintXX_t types in inttypes.h... yes
...

It should not be looking for uintXX_t in inttypes.h if the header is
unuseable (ie. ac_cv_header_inttypes_h=no).

Patch attached.
It will avoid the extra testing for types in headers we already know are not available.
This follows the style already found in configure.ac.

It fixes the build on IRIX 5.3 when using the SGI compiler, and a quick test on CentOS 6.5 verifies that it makes no difference there.

Also even if inttypes.h is available and defines uintXX_t, the source does not seem to make consistent use of it (only used in roaming_*.c).

This part I've not touched.
There is some inconsistence in the use of <stdint.h> and <inttypes.h>.
In includes.h <stdint.h> is always included if HAVE_STDINT_H is true, in which case it makes no sense that poly1305.c also includes it. The roaming_c*.c files check for HAVE_INTTYPES_H and includes it if available, but relies on includes.h otherwise.

Should includes.h simply check HAVE_INTTYPES_H? perhaps only if HAVE_STDINT_H is not defined?

-tgc
>From 1ce7e8e19988ce23d6d058d358a93f9f608dfec5 Mon Sep 17 00:00:00 2001
From: Tom G. Christensen <tgc@xxxxxxxxxxxxxxx>
Date: Tue, 28 Jan 2014 20:47:14 +0100
Subject: [PATCH 2/2] [configure.ac] only look for types in useable headers

---
 configure.ac |   12 +++++++++---
 1 files changed, 9 insertions(+), 3 deletions(-)

diff --git a/configure.ac b/configure.ac
index 669e169..8c9ed21 100644
--- a/configure.ac
+++ b/configure.ac
@@ -3271,7 +3271,9 @@ if test "x$ac_cv_have_u_int64_t" = "xyes" ; then
 	have_u_int64_t=1
 fi
 
-if test -z "$have_u_int64_t" ; then
+if (test -z "$have_u_int64_t" && \
+	   test "x$ac_cv_header_sys_bitypes_h" = "xyes")
+then
     AC_MSG_CHECKING([for u_int64_t type in sys/bitypes.h])
 	AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ #include <sys/bitypes.h> ]],
 	[[ u_int64_t a; a = 1]])],
@@ -3301,7 +3303,9 @@ if test -z "$have_u_intxx_t" ; then
 	fi
 fi
 
-if test -z "$have_uintxx_t" ; then
+if (test -z "$have_uintxx_t" && \
+	   test "x$ac_cv_header_stdint_h" = "xyes")
+then
     AC_MSG_CHECKING([for uintXX_t types in stdint.h])
 	AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ #include <stdint.h> ]],
 	[[ uint8_t a; uint16_t b; uint32_t c; a = b = c = 1;]])],
@@ -3312,7 +3316,9 @@ if test -z "$have_uintxx_t" ; then
 	])
 fi
 
-if test -z "$have_uintxx_t" ; then
+if (test -z "$have_uintxx_t" && \
+	   test "x$ac_cv_header_inttypes_h" = "xyes")
+then
     AC_MSG_CHECKING([for uintXX_t types in inttypes.h])
 	AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ #include <inttypes.h> ]],
 	[[ uint8_t a; uint16_t b; uint32_t c; a = b = c = 1;]])],
-- 
1.7.1

_______________________________________________
openssh-unix-dev mailing list
openssh-unix-dev@xxxxxxxxxxx
https://lists.mindrot.org/mailman/listinfo/openssh-unix-dev

[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux