From a56f191ef1e9517c97426e9b944e4feb94294fe2 Mon Sep 17 00:00:00 2001 From: Darren Tucker Date: Tue, 2 Nov 2004 20:30:54 +1100 Subject: - (dtucker) [configure.ac includes.h] Bug #947: Fix compile error on HP-UX 10.x by testing for conflicts in shadow.h and undef'ing _INCLUDE__STDC__ only if a conflict is detected. --- configure.ac | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index e8bee9d4e..b8f970074 100644 --- a/configure.ac +++ b/configure.ac @@ -1,4 +1,4 @@ -# $Id: configure.ac,v 1.231 2004/09/30 11:17:08 dtucker Exp $ +# $Id: configure.ac,v 1.232 2004/11/02 09:30:54 dtucker Exp $ # # Copyright (c) 1999-2004 Damien Miller # @@ -220,6 +220,7 @@ main() { if (NSVersionOfRunTimeLibrary("System") >= (60 << 16)) AC_DEFINE(LOCKED_PASSWD_STRING, "*") AC_DEFINE(SPT_TYPE,SPT_PSTAT) check_for_hpux_broken_getaddrinfo=1 + check_for_conflicting_getspnam=1 LIBS="$LIBS -lsec" AC_CHECK_LIB(xnet, t_error, ,AC_MSG_ERROR([*** -lxnet needed on HP-UX - check config.log ***])) ;; @@ -1123,6 +1124,24 @@ main(void) ) fi +if test "x$check_for_conflicting_getspnam" = "x1"; then + AC_MSG_CHECKING(for conflicting getspnam in shadow.h) + AC_COMPILE_IFELSE( + [ +#include +int main(void) {exit(0);} + ], + [ + AC_MSG_RESULT(no) + ], + [ + AC_MSG_RESULT(yes) + AC_DEFINE(GETSPNAM_CONFLICTING_DEFS, 1, + [Conflicting defs for getspnam]) + ] + ) +fi + AC_FUNC_GETPGRP # Check for PAM libs -- cgit v1.2.3