dnl Process this file with autoconf to produce a configure script dnl Initialization AC_PREREQ(2.50) AC_INIT AC_CONFIG_SRCDIR(src/lwp.c) CODA_SETUP_BUILD AM_INIT_AUTOMAKE(lwp, 2.3) AC_CONFIG_HEADERS(config.h) dnl For library version updates, follow these steps in order. dnl - when any library source has changed, increment first dnl - when interfaces were added/removed changed, increment second and set dnl first to 0 dnl - if any interfaces were added, increment third dnl - if any interfaces were removed, set third to 0 CODA_LIBRARY_VERSION(6, 2, 0) CONFIG_DATE=`date +"%a, %d %b %Y %T %z"` AC_SUBST(CONFIG_DATE, "$CONFIG_DATE", [Date when configure was last run]) dnl Checks for programs. AC_PROG_CC AC_PROG_CPP AC_CHECK_PROG(AR, ar, ar) AM_PROG_AS AC_PROG_INSTALL AC_PROG_MAKE_SET AC_PROG_LIBTOOL dnl Checks for libraries. AC_SUBST(LIBPTHREAD) AC_ARG_ENABLE(pthread, [ --enable-pthread build experimental pthreaded LWP library], includepthread="$enableval", includepthread="no") AC_CHECK_LIB(pthread, pthread_create, [LIBPTHREAD="-lpthread"]) AC_CHECK_LIB(posix4, sem_init, [LIBPTHREAD="${LIBPTHREAD} -lposix4"]) AM_CONDITIONAL(build_pthread, test "$includepthread" != "no" -a "x$LIBPTHREAD" != x) dnl Checks for header files. AC_CHECK_HEADERS(ucontext.h) CODA_CHECK_MAKECONTEXT dnl Checks for typedefs. AC_CHECK_TYPES(register_t) AC_CHECK_TYPES(stack_t,,, [#include ]) dnl Checks for library functions. AC_CHECK_FUNCS(sigaltstack) AC_FUNC_MMAP dnl Checks for system services. dnl Generate output files AC_SUBST(AFLAGS) AC_CONFIG_FILES(Makefile include/Makefile include/lwp/Makefile src/Makefile src-pt/Makefile pkgs/Makefile pkgs/pkg-bsd.sh pkgs/lwp.spec debian/Makefile debian/changelog) AC_OUTPUT