$OpenBSD: patch-configure_ac,v 1.5 2017/09/25 10:06:12 sthen Exp $

Disable the noisy warnings, it makes it hard to see the more important basic
problems (missing prototypes for internal functions, etc - lots of sloppiness)
in amongst the chaff.

Prefer libedit over libreadline.

Fix bad AC_TRY_COMPILE check.

Index: configure.ac
--- configure.ac.orig
+++ configure.ac
@@ -32,7 +32,7 @@ AC_CHECK_FUNCS([alarm gethostbyname getaddrinfo getifa
 AC_CHECK_FUNCS([memmove memset strchr strdup strerror])
 AC_CHECK_FUNCS([getpassphrase])
 
-CFLAGS="$CFLAGS -Wall -Wextra -std=gnu99 -pedantic -Wformat -Wformat-nonliteral"
+CFLAGS="$CFLAGS -std=gnu99 -Wformat"
 
 AM_PROG_LIBTOOL
 LIBTOOL="$LIBTOOL --silent"
@@ -570,7 +570,7 @@ AC_SUBST(IPMITOOL_INTF_LIB)
 if test "x$xenable_ipmishell" = "xyes"; then
 	AC_SEARCH_LIBS([tgetent], [tinfo ncurses curses readline termcap])
 	AC_SEARCH_LIBS([initscr], [ncurses curses], [have_curses=yes])
-	AC_SEARCH_LIBS([readline], [readline edit], [have_readline=yes])
+	AC_SEARCH_LIBS([readline], [edit readline], [have_readline=yes])
 	if test "x$have_curses" != "xyes" || test "x$have_readline" != "xyes"; then
 		xenable_ipmishell=no
 	fi
@@ -617,9 +617,7 @@ if test "x$xenable_file_security" != "xno"; then
 fi
 
 
-AC_TRY_COMPILE([],[
-	#include <stdio.h>
-	
+AC_TRY_COMPILE([#include <stdio.h>],[
 	struct packstruct {
 		unsigned char t0       :5;
 		unsigned char t1       :5;
@@ -628,14 +626,10 @@ AC_TRY_COMPILE([],[
 		unsigned char t4       :4;
 	} __attribute__ ((packed));
 	
-	int
-	main(int argc, char ** argv)
-	{
 	if(sizeof(struct packstruct) != 3)
 	return(1);
 	else
 	return(0);
-	}
 	],
 	[],
 	[AC_DEFINE(HAVE_PRAGMA_PACK,[1],
