dnl dnl Configuration things for affyR. dnl (http://www.cbs.dtu.dk/laurent/download/affyR/ dnl What is below (and in the other configuration fiels dnl was taken from different configuration scripts for R version 1.3.0. dnl dnl Acknowledgments: The author(s) of the R configure scripts, Kurt Hornik for the tip with autoconf. dnl dnl Laurent 2001 AC_INIT("DESCRIPTION") dnl dnl Are things (still) the same ? dnl (taken from the 'writing R extensions manual') AC_CHECK_LIB(pthread, pthread_create) AC_TRY_LINK_FUNC(pthread_create, [use_pthreads=yes], [use_pthreads=no]) AC_MSG_CHECKING([if we can use pthreads]) AC_MSG_RESULT($use_pthreads) AC_MSG_CHECKING([if PTHREAD_STACK_MIN is defined]) AC_COMPILE_IFELSE([ #include <pthread.h> #include <limits.h> int main () {size_t stacksize = PTHREAD_STACK_MIN + 0x4000; } ],[use_pthread_stack_min=yes], [use_pthread_stack_min=no]) AC_MSG_RESULT($use_pthread_stack_min) if test "x$use_pthreads" = "xyes" then if test "x$use_pthread_stack_min" = "xyes" then LIBS="$LIBS -lpthread" AC_DEFINE(USE_PTHREADS, 1) fi fi AC_OUTPUT(src/Makevars)