--- slang-1.4.9/autoconf/configure.in.old 2002-09-13 13:53:56.000000000 +0200 +++ slang-1.4.9/autoconf/configure.in 2002-09-13 14:01:44.000000000 +0200 @@ -17,6 +17,62 @@ AC_CONFIG_AUX_DIR(autoconf) AC_CANONICAL_HOST +AH_TOP([ +/* -*- c -*- */ +/* Note: this is for unix only. */ + +#ifndef SL_CONFIG_H +#define SL_CONFIG_H +]) + +AH_BOTTOM([ +#if defined(HAVE_SIGADDSET) && defined(HAVE_SIGEMPTYSET) +# if defined(HAVE_SIGACTION) && defined(HAVE_SIGPROCMASK) +# define SLANG_POSIX_SIGNALS +# endif +#endif + +/* Define if you need to in order for stat and other things to work. */ +#undef _POSIX_SOURCE + +#ifdef _AIX +# ifndef _POSIX_SOURCE +# define _POSIX_SOURCE 1 +# endif +# ifndef _ALL_SOURCE +# define _ALL_SOURCE +# endif +/* This may generate warnings but the fact is that without it, xlc will + * INCORRECTLY inline many str* functions. */ +# undef __STR__ +#endif + +/* define USE_TERMCAP if you want to use it instead of terminfo. */ +#if defined(sequent) || defined(NeXT) +# ifndef USE_TERMCAP +# define USE_TERMCAP +# endif +#endif + +#if defined(ultrix) && !defined(__GNUC__) +# ifndef NO_PROTOTYPES +# define NO_PROTOTYPES +# endif +#endif + +#ifndef unix +# define unix 1 +#endif + +#ifndef __unix__ +# define __unix__ 1 +#endif + +#define _SLANG_SOURCE_ 1 +#endif /* SL_CONFIG_H */ +]) + + JD_INIT JD_ANSI_CC @@ -69,9 +125,9 @@ times gmtime \ ) -AC_CHECK_LIB(m, acosh, [AC_DEFINE(HAVE_ACOSH)]) -AC_CHECK_LIB(m, asinh, [AC_DEFINE(HAVE_ASINH)]) -AC_CHECK_LIB(m, atanh, [AC_DEFINE(HAVE_ATANH)]) +AC_CHECK_LIB(m, acosh, [AC_DEFINE(HAVE_ACOSH,1,[Define to 1 if you have the `acosh' function])]) +AC_CHECK_LIB(m, asinh, [AC_DEFINE(HAVE_ASINH,1,[Define to 1 if you have the `asinh' function])]) +AC_CHECK_LIB(m, atanh, [AC_DEFINE(HAVE_ATANH,1,[Define to 1 if you have the `atanh' function])]) JD_ELF_COMPILER JD_IEEE_CFLAGS --- slang-1.4.9/utoconf/aclocal.m4.old 2002-09-13 13:35:17.000000000 +0200 +++ slang-1.4.9/autoconf/aclocal.m4 2002-09-13 14:16:10.000000000 +0200 @@ -258,18 +258,18 @@ AC_DEFUN(JD_GCC_WARNINGS, [ AC_ARG_ENABLE(warnings, - [ --enable-warnings turn on GCC compiler warnings], + AC_HELP_STRING([--enable-warnings],[turn on GCC compiler warnings]), [gcc_warnings=$enableval]) -if test -n "$GCC" +if test -n "$GCC" && test -n "$gcc_warnings" then - CFLAGS="$CFLAGS -fno-strength-reduce" - if test -n "$gcc_warnings" - then - CFLAGS="$CFLAGS -Wall -W -pedantic -Winline -Wmissing-prototypes \ - -Wnested-externs -Wpointer-arith -Wcast-align -Wshadow -Wstrict-prototypes" - # Now trim excess whitespace - CFLAGS=`echo $CFLAGS` - fi + CFLAGS="$CFLAGS -Wall -W -pedantic -Winline -Wmissing-prototypes \ + -Wnested-externs -Wpointer-arith -Wcast-align -Wshadow -Wstrict-prototypes \ + -Wformat -Wformat-security" + ELF_CFLAGS="$ELF_CFLAGS -Wall -W -pedantic -Winline -Wmissing-prototypes \ + -Wnested-externs -Wpointer-arith -Wcast-align -Wshadow -Wstrict-prototypes \ + -Wformat -Wformat-security" + # Now trim excess whitespace + CFLAGS=`echo $CFLAGS` fi ]) @@ -415,7 +415,7 @@ done if test "$TERMCAP"; then AC_MSG_RESULT(no) - AC_DEFINE(USE_TERMCAP) + AC_DEFINE(USE_TERMCAP,1,[Define to use termcap]) fi AC_SUBST(TERMCAP)dnl AC_SUBST(MISC_TERMINFO_DIRS)dnl @@ -439,7 +439,7 @@ yes #endif ], [ -AC_DEFINE(_HPUX_SOURCE) +AC_DEFINE(_HPUX_SOURCE,1,[Special define needed for HPUX]) if test "$CC" = cc; then CC="cc -Ae"; fi ])dnl dnl @@ -462,8 +462,11 @@ dnl # Check for dynamic linker dnl #------------------------------------------------------------------------- DYNAMIC_LINK_LIB="" + +AH_TEMPLATE([HAVE_DLOPEN],[Define if you have dlopen]) + AC_CHECK_HEADER(dlfcn.h,[ - AC_DEFINE(HAVE_DLFCN_H) + AC_DEFINE(HAVE_DLFCN_H,1,[Define if you have the dlfcn.h header]) AC_CHECK_LIB(dl,dlopen,[ DYNAMIC_LINK_LIB="-ldl" AC_DEFINE(HAVE_DLOPEN) @@ -484,7 +487,7 @@ *linux* ) DYNAMIC_LINK_FLAGS="-Wl,-export-dynamic" ELF_CC="gcc" - ELF_CFLAGS="-O2 -fno-strength-reduce -fPIC" + ELF_CFLAGS="$ELF_CFLAGS -fPIC" ELF_LINK="gcc -shared -Wl,-soname#" ELF_LINK_CMD="\$(ELF_LINK),\$(ELFLIB_MAJOR)" ELF_DEP_LIBS="\$(DL_LIB) -lm -lc"