1dnl This file is an input file used by the GNU "autoconf" program to 2dnl generate the file "configure", which tries to guess your system 3dnl configuration so that no manual editing of the Makefile should be 4dnl necessary 5dnl 6dnl $Id: configure.in,v 1.25 2004/03/01 23:06:22 fp Exp $ 7dnl 8 9AC_INIT(uulib.c) 10AC_PREREQ(2.9) 11AC_CONFIG_HEADER(config.h) 12 13# 14# package revision 15# 16VERSION=0.5 17PATCH=20 18 19AC_PROG_CC 20AC_PROG_CPP 21wi_PROTOTYPES 22AC_PROG_MAKE_SET 23AC_PROG_RANLIB 24 25if test "$wi_cv_prototypes" = no ; then 26 AC_WARN([Your compiler does not support function prototyping and]) 27 AC_WARN([is not able to properly compile this package. What a pity.]) 28 AC_WARN([Get gcc, or any compiler that supports function prototypes.]) 29 exit 1 30fi 31 32# 33# Checks for header files and library functions 34# 35 36AC_HEADER_STDC 37AC_TYPE_SIZE_T 38AC_HEADER_TIME 39AC_CHECK_HEADERS(fcntl.h unistd.h memory.h malloc.h errno.h) 40AC_CHECK_HEADERS(io.h sys/time.h) 41AC_CHECK_FUNCS(gettimeofday) 42 43AC_CHECK_FUNC(tempnam,,AC_DEFINE(tempnam,_FP_tempnam)) 44 45# 46# strerror might be internally defined. this would cause a 47# CHECK_FUNCS(strerror) to fail because it'd be called with 48# zero arguments. So use our own code. 49# 50AC_MSG_CHECKING([for strerror]) 51AC_TRY_LINK([ 52char *blubb() { return (char *) strerror (42); } 53],[ 54(void) blubb(); 55],have_strerror=yes,AC_DEFINE(strerror,_FP_strerror) 56have_strerror=no) 57AC_MSG_RESULT($have_strerror) 58 59AC_MSG_CHECKING([for stdin]) 60AC_TRY_LINK([ 61#include <stdio.h> 62char *blubb() { FILE *in, *out; in=stdin; out=stdout; return (char*)0; } 63],[ 64(void) blubb(); 65],have_stdio=yes,AC_DEFINE(HAVE_STDIO) 66have_stdio=no) 67AC_MSG_RESULT($have_stdio) 68 69if test "$ac_cv_header_stdc" = "no" ; then 70 AC_CHECK_HEADERS(stdarg.h varargs.h) 71 if test "$ac_cv_header_stdarg_h" = "no" ; then 72 if test "$ac_cv_header_varargs_h" = "no" ; then 73 AC_MSG_ERROR([neither stdarg.h nor varargs.h present]) 74 fi 75 fi 76fi 77 78# 79# Check whether this is a DOS-Based system. Another bogus test. 80# Don't even bother to print a message. This code is needed so 81# that autoheader includes the #undef into the final config.h 82# and we can change the definition by hand on a really DOS 83# system (where ./configure doesn't work anyway ...) 84# 85 86if false ; then 87 AC_DEFINE(SYSTEM_DOS) 88 AC_DEFINE(SYSTEM_QUICKWIN) 89 AC_DEFINE(SYSTEM_WINDLL) 90 AC_DEFINE(SYSTEM_OS2) 91fi 92 93# 94# On some systems (so far, OS2 and WINDOWS), functions that are exported 95# from a DLL must be declared specifically. 96# 97 98AC_DEFINE_UNQUOTED(UUEXPORT,) 99AC_DEFINE_UNQUOTED(TOOLEXPORT,) 100 101# 102# set version number 103# 104AC_MSG_CHECKING([version number]) 105version_number="$VERSION"pl"$PATCH" 106AC_MSG_RESULT($version_number) 107AC_SUBST(VERSION) 108AC_SUBST(PATCH) 109 110# 111# done 112# 113 114AC_OUTPUT(Makefile) 115