configure 497 KB
Newer Older
13001
13002
13003
13004
13005
13006
13007
13008
13009
13010
13011
13012
13013
13014
13015
13016
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
  acx_pthread_ok=yes
fi
rm -f core conftest.err conftest.$ac_objext \
    conftest$ac_exeext conftest.$ac_ext
        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_pthread_ok" >&5
$as_echo "$acx_pthread_ok" >&6; }
        if test x"$acx_pthread_ok" = xno; then
                PTHREAD_LIBS=""
                PTHREAD_CFLAGS=""
        fi
        LIBS="$save_LIBS"
        CFLAGS="$save_CFLAGS"
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13017

13018
13019
13020
# Create a list of thread flags to try.  Items starting with a "-" are
# C compiler flags, and other items are library names, except for "none"
# which indicates that we try without any flags at all.
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13021

13022
acx_pthread_flags="pthreads none -Kthread -kthread lthread pthread -pthread -pthreads -mthreads --thread-safe -mt"
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13023

13024
13025
# The ordering *is* (sometimes) important.  Some notes on the
# individual items follow:
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13026

13027
13028
13029
13030
13031
13032
13033
13034
13035
13036
13037
13038
13039
13040
# pthreads: AIX (must check this before -lpthread)
# none: in case threads are in libc; should be tried before -Kthread and
#       other compiler flags to prevent continual compiler warnings
# -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
# -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
# lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
# -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
# -pthreads: Solaris/gcc
# -mthreads: Mingw32/gcc, Lynx/gcc
# -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
#      doesn't hurt to check since this sometimes defines pthreads too;
#      also defines -D_REENTRANT)
# pthread: Linux, etcetera
# --thread-safe: KAI C++
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13041

13042
13043
case "${host_cpu}-${host_os}" in
        *solaris*)
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13044

13045
13046
13047
13048
13049
13050
13051
        # On Solaris (at least, for some versions), libc contains stubbed
        # (non-functional) versions of the pthreads routines, so link-based
        # tests will erroneously succeed.  (We need to link with -pthread or
        # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
        # a function called by this macro, so we could check for that, but
        # who knows whether they'll stub that too in a future libc.)  So,
        # we'll just look for -pthreads and -lpthread first:
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13052

13053
13054
13055
        acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
        ;;
esac
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13056

13057
13058
if test x"$acx_pthread_ok" = xno; then
for flag in $acx_pthread_flags; do
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13059

13060
13061
13062
13063
13064
        case $flag in
                none)
                { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
$as_echo_n "checking whether pthreads work without any flags... " >&6; }
                ;;
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13065

13066
13067
13068
13069
13070
                -*)
                { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $flag" >&5
$as_echo_n "checking whether pthreads work with $flag... " >&6; }
                PTHREAD_CFLAGS="$flag"
                ;;
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13071

13072
13073
13074
13075
13076
13077
                *)
                { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$flag" >&5
$as_echo_n "checking for the pthreads library -l$flag... " >&6; }
                PTHREAD_LIBS="-l$flag"
                ;;
        esac
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13078

13079
13080
13081
13082
        save_LIBS="$LIBS"
        save_CFLAGS="$CFLAGS"
        LIBS="$PTHREAD_LIBS $LIBS"
        CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13083

13084
13085
13086
13087
13088
13089
13090
13091
13092
13093
        # Check for various functions.  We must include pthread.h,
        # since some functions may be macros.  (On the Sequent, we
        # need a special flag -Kthread to make this header compile.)
        # We check for pthread_join because it is in -lpthread on IRIX
        # while pthread_create is in libc.  We check for pthread_attr_init
        # due to DEC craziness with -lpthreads.  We check for
        # pthread_cleanup_push because it is one of the few pthread
        # functions on Solaris that doesn't have a non-functional libc stub.
        # We try pthread_create on general principles.
        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13094
/* end confdefs.h.  */
13095
#include <pthread.h>
13096
13097
13098
int
main ()
{
13099
13100
13101
pthread_t th; pthread_join(th, 0);
                     pthread_attr_init(0); pthread_cleanup_push(0, 0);
                     pthread_create(0,0,0,0); pthread_cleanup_pop(0);
13102
13103
13104
13105
13106
  ;
  return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
13107
  acx_pthread_ok=yes
13108
13109
13110
fi
rm -f core conftest.err conftest.$ac_objext \
    conftest$ac_exeext conftest.$ac_ext
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13111

13112
13113
13114
13115
13116
13117
13118
13119
        LIBS="$save_LIBS"
        CFLAGS="$save_CFLAGS"

        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_pthread_ok" >&5
$as_echo "$acx_pthread_ok" >&6; }
        if test "x$acx_pthread_ok" = xyes; then
                break;
        fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13120

13121
13122
13123
13124
13125
13126
13127
13128
13129
13130
13131
13132
13133
13134
13135
13136
13137
13138
13139
        PTHREAD_LIBS=""
        PTHREAD_CFLAGS=""
done
fi

# Various other checks:
if test "x$acx_pthread_ok" = xyes; then
        save_LIBS="$LIBS"
        LIBS="$PTHREAD_LIBS $LIBS"
        save_CFLAGS="$CFLAGS"
        CFLAGS="$CFLAGS $PTHREAD_CFLAGS"

        # Detect AIX lossage: threads are created detached by default
        # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
$as_echo_n "checking for joinable pthread attribute... " >&6; }
        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h.  */
#include <pthread.h>
13140
13141
13142
int
main ()
{
13143
int attr=PTHREAD_CREATE_JOINABLE;
13144
13145
13146
13147
13148
  ;
  return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
13149
13150
13151
  ok=PTHREAD_CREATE_JOINABLE
else
  ok=unknown
13152
fi
13153
13154
13155
13156
13157
13158
13159
13160
13161
13162
13163
13164
13165
13166
13167
13168
13169
13170
rm -f core conftest.err conftest.$ac_objext \
    conftest$ac_exeext conftest.$ac_ext
        if test x"$ok" = xunknown; then
                cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h.  */
#include <pthread.h>
int
main ()
{
int attr=PTHREAD_CREATE_UNDETACHED;
  ;
  return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
  ok=PTHREAD_CREATE_UNDETACHED
else
  ok=unknown
13171
13172
13173
fi
rm -f core conftest.err conftest.$ac_objext \
    conftest$ac_exeext conftest.$ac_ext
13174
13175
        fi
        if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13176

13177
$as_echo "#define PTHREAD_CREATE_JOINABLE \$ok" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13178

13179
13180
13181
13182
13183
13184
13185
        fi
        { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ok}" >&5
$as_echo "${ok}" >&6; }
        if test x"$ok" = xunknown; then
                { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: we do not know how to create joinable pthreads" >&5
$as_echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
        fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13186

13187
13188
13189
13190
13191
13192
13193
13194
13195
13196
13197
13198
        { $as_echo "$as_me:${as_lineno-$LINENO}: checking if more special flags are required for pthreads" >&5
$as_echo_n "checking if more special flags are required for pthreads... " >&6; }
        flag=no
        case "${host_cpu}-${host_os}" in
                *-aix* | *-freebsd*)     flag="-D_THREAD_SAFE";;
                *solaris* | alpha*-osf*) flag="-D_REENTRANT";;
        esac
        { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${flag}" >&5
$as_echo "${flag}" >&6; }
        if test "x$flag" != xno; then
                PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
        fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13199

13200
13201
        LIBS="$save_LIBS"
        CFLAGS="$save_CFLAGS"
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13202

13203
13204
13205
13206
13207
13208
13209
13210
13211
13212
13213
13214
13215
13216
13217
13218
13219
13220
13221
13222
13223
13224
13225
13226
13227
        # More AIX lossage: must compile with cc_r
        # Extract the first word of "cc_r", so it can be a program name with args.
set dummy cc_r; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if ${ac_cv_prog_PTHREAD_CC+:} false; then :
  $as_echo_n "(cached) " >&6
else
  if test -n "$PTHREAD_CC"; then
  ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
    for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_PTHREAD_CC="cc_r"
    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
  done
IFS=$as_save_IFS
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13228

13229
13230
13231
13232
13233
13234
13235
13236
13237
13238
13239
  test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
fi
fi
PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
if test -n "$PTHREAD_CC"; then
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
$as_echo "$PTHREAD_CC" >&6; }
else
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13240
13241


13242
13243
13244
else
        PTHREAD_CC="$CC"
fi
13245

Emmanuel Bertin's avatar
Emmanuel Bertin committed
13246
13247
13248
13249




13250
13251
# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
if test x"$acx_pthread_ok" = xyes; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13252

13253
$as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13254

13255
13256
13257
        :
else
        acx_pthread_ok=no
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13258

13259
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13260
13261


13262
13263
13264
13265
13266
13267
13268
13269
13270
13271
13272
  CC="$PTHREAD_CC"
  AM_CFLAGS="$AM_CFLAGS $PTHREAD_CFLAGS -D_REENTRANT"
  LIBS="$PTHREAD_LIBS $LIBS"
fi
 if test $use_pthreads = "yes"; then
  USE_THREADS_TRUE=
  USE_THREADS_FALSE='#'
else
  USE_THREADS_TRUE='#'
  USE_THREADS_FALSE=
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13273
13274


13275
13276
13277
if test "$enable_model_fitting" = "yes"; then
############ handle the INTEL MKL library (FFTW + LAPACK) ###########
  if test "$enable_mkl" = "yes"; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13278
13279
13280
13281




13282
13283
if icc -V 2>&1 | grep -i "Intel(R) 64" > /dev/null 2>&1; then
  MKL_CFLAGS="-DMKL_ILP64"
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13284

13285
  MKL_LIBS="-mkl"
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13286

13287
13288
elif icc -V 2>&1 | grep -i "Intel(R)" > /dev/null 2>&1; then
  MKL_CFLAGS=""
13289

13290
  MKL_LIBS="-mkl"
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13291

13292
13293
else
  MKL_CFLAGS=""
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13294

13295
  MKL_LIBS=""
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13296

13297
  MKL_WARN="INTEL compiler not detected"
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13298

13299
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13300
13301
13302



13303
$as_echo "#define HAVE_FFTW 1" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13304
13305


13306
$as_echo "#define HAVE_LAPACK 1" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13307
13308


13309
$as_echo "#define HAVE_LAPACKE 1" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13310
13311
13312
13313




13314
13315
13316
cat >>confdefs.h <<_ACEOF
#define FFTW_H "fftw/fftw3_mkl.h"
_ACEOF
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13317
13318


13319
13320
13321
cat >>confdefs.h <<_ACEOF
#define LAPACK_H "mkl_lapack.h"
_ACEOF
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13322
13323


13324
13325
13326
cat >>confdefs.h <<_ACEOF
#define LAPACKE_H "mkl_lapacke.h"
_ACEOF
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13327

13328
13329
13330
13331
13332
13333
13334
13335
13336



    if test "$MKL_WARN" != ""; then
      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $MKL_WARN" >&5
$as_echo "$as_me: WARNING: $MKL_WARN" >&2;}
    fi
    AM_CFLAGS="$AM_CFLAGS $MKL_CFLAGS "
    LIBS="$MKL_LIBS $LIBS"
13337
  else
13338
13339
13340
13341
13342
13343
13344
13345
13346
13347
13348
13349
13350
13351
13352
13353
13354
13355
13356
13357
13358
13359
13360
13361
13362
13363
13364
13365
13366
################ handle the FFTW library (Fourier transforms) ################




acx_fftw_ok=no
if test x$with_fftw_incdir = x; then
  if test x$with_fftw_libdir = x; then
    ac_fn_c_check_header_mongrel "$LINENO" "fftw3.h" "ac_cv_header_fftw3_h" "$ac_includes_default"
if test "x$ac_cv_header_fftw3_h" = xyes; then :
  acx_fftw_ok=yes
fi


    if test x$acx_fftw_ok = xyes; then

$as_echo "#define FFTW_H \"fftw3.h\"" >>confdefs.h

    else
      ac_fn_c_check_header_mongrel "$LINENO" "fftw/fftw3.h" "ac_cv_header_fftw_fftw3_h" "$ac_includes_default"
if test "x$ac_cv_header_fftw_fftw3_h" = xyes; then :
  acx_fftw_ok=yes
fi


      if test x$acx_fftw_ok = xyes; then

$as_echo "#define FFTW_H \"fftw/fftw3.h\"" >>confdefs.h

13367
      else
13368
        FFTW_ERROR="FFTW include files not found in default location!"
13369
13370
      fi
    fi
13371
13372
13373
13374
13375
13376
  else
    as_ac_Header=`$as_echo "ac_cv_header_$with_fftw_libdir/include/fftw3.h" | $as_tr_sh`
ac_fn_c_check_header_mongrel "$LINENO" "$with_fftw_libdir/include/fftw3.h" "$as_ac_Header" "$ac_includes_default"
if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  acx_fftw_ok=yes
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13377
13378


13379
    if test x$acx_fftw_ok = xyes; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13380

13381
$as_echo "#define FFTW_H \$with_fftw_libdir\"/include/fftw3.h" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13382

13383
13384
13385
13386
13387
    else
      ac_fn_c_check_header_mongrel "$LINENO" "fftw3.h" "ac_cv_header_fftw3_h" "$ac_includes_default"
if test "x$ac_cv_header_fftw3_h" = xyes; then :
  acx_fftw_ok=yes
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13388
13389


13390
      if test x$acx_fftw_ok = xyes; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13391

13392
$as_echo "#define FFTW_H \"fftw3.h\"" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13393

13394
13395
13396
13397
13398
13399
13400
13401
13402
13403
13404
      else
        FFTW_ERROR="FFTW include files not found in $with_fftw_libdir/include!"
      fi
    fi
  fi
else
  as_ac_Header=`$as_echo "ac_cv_header_$with_fftw_incdir/fftw3.h" | $as_tr_sh`
ac_fn_c_check_header_mongrel "$LINENO" "$with_fftw_incdir/fftw3.h" "$as_ac_Header" "$ac_includes_default"
if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  acx_fftw_ok=yes
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13405
13406


13407
  if test x$acx_fftw_ok = xyes; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13408

13409
13410
13411
cat >>confdefs.h <<_ACEOF
#define FFTW_H "$with_fftw_incdir/fftw3.h"
_ACEOF
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13412

13413
  else
13414
    FFTW_ERROR="FFTW include files not found in $with_fftw_incdir!"
13415
  fi
13416
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13417
13418


13419
13420
13421
FFTW_LIBS=""
OLIBS="$LIBS"
LIBS=""
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13422

13423
13424
13425
13426
13427
13428
13429
13430
13431
13432
13433
13434
if test x$acx_fftw_ok = xyes; then
  if test x$with_fftw_libdir = x; then
    if test xyes = xyes; then
      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fftwf_execute in -lfftw3f" >&5
$as_echo_n "checking for fftwf_execute in -lfftw3f... " >&6; }
if ${ac_cv_lib_fftw3f_fftwf_execute+:} false; then :
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lfftw3f -lm $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h.  */
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13435

13436
13437
13438
13439
13440
13441
13442
13443
13444
13445
13446
13447
13448
13449
13450
13451
13452
13453
13454
13455
13456
13457
13458
13459
13460
13461
13462
13463
13464
13465
13466
/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char fftwf_execute ();
int
main ()
{
return fftwf_execute ();
  ;
  return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
  ac_cv_lib_fftw3f_fftwf_execute=yes
else
  ac_cv_lib_fftw3f_fftwf_execute=no
fi
rm -f core conftest.err conftest.$ac_objext \
    conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fftw3f_fftwf_execute" >&5
$as_echo "$ac_cv_lib_fftw3f_fftwf_execute" >&6; }
if test "x$ac_cv_lib_fftw3f_fftwf_execute" = xyes; then :
  acx_fftw_ok=yes
else
  acx_fftw_ok=no
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13467

13468
      if test x$acx_fftw_ok = xyes; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13469

13470
$as_echo "#define HAVE_FFTWF 1" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13471

13472
13473
13474
13475
13476
13477
13478
13479
13480
13481
13482
13483
13484
13485
        FFTW_LIBS="-lfftw3f"
      else
        FFTW_ERROR="FFTW single precision library files not found at usual locations!"
      fi
    else
      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fftw_execute in -lfftw3" >&5
$as_echo_n "checking for fftw_execute in -lfftw3... " >&6; }
if ${ac_cv_lib_fftw3_fftw_execute+:} false; then :
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lfftw3 -lm $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h.  */
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13486

13487
13488
13489
13490
13491
13492
13493
13494
13495
13496
13497
13498
13499
13500
13501
13502
13503
13504
13505
13506
13507
13508
13509
13510
13511
13512
13513
13514
13515
13516
13517
/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char fftw_execute ();
int
main ()
{
return fftw_execute ();
  ;
  return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
  ac_cv_lib_fftw3_fftw_execute=yes
else
  ac_cv_lib_fftw3_fftw_execute=no
fi
rm -f core conftest.err conftest.$ac_objext \
    conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fftw3_fftw_execute" >&5
$as_echo "$ac_cv_lib_fftw3_fftw_execute" >&6; }
if test "x$ac_cv_lib_fftw3_fftw_execute" = xyes; then :
  acx_fftw_ok=yes
else
  acx_fftw_ok=no
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13518

13519
      if test x$acx_fftw_ok = xyes; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13520

13521
$as_echo "#define HAVE_FFTW 1" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13522

13523
13524
13525
13526
13527
13528
13529
13530
13531
13532
13533
13534
13535
13536
13537
13538
        FFTW_LIBS="-lfftw3"
      else
        FFTW_ERROR="FFTW double precision library files not found at usual locations!"
      fi
    fi
    if test x$acx_fftw_ok = xyes && test x$use_pthreads = xyes; then
      if test xyes = xyes; then
        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fftwf_init_threads in -lfftw3f" >&5
$as_echo_n "checking for fftwf_init_threads in -lfftw3f... " >&6; }
if ${ac_cv_lib_fftw3f_fftwf_init_threads+:} false; then :
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lfftw3f -lm -lpthread $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h.  */
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13539

13540
13541
13542
13543
13544
13545
13546
13547
13548
13549
13550
13551
13552
13553
13554
13555
13556
13557
13558
13559
13560
13561
13562
13563
13564
13565
13566
13567
13568
13569
13570
/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char fftwf_init_threads ();
int
main ()
{
return fftwf_init_threads ();
  ;
  return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
  ac_cv_lib_fftw3f_fftwf_init_threads=yes
else
  ac_cv_lib_fftw3f_fftwf_init_threads=no
fi
rm -f core conftest.err conftest.$ac_objext \
    conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fftw3f_fftwf_init_threads" >&5
$as_echo "$ac_cv_lib_fftw3f_fftwf_init_threads" >&6; }
if test "x$ac_cv_lib_fftw3f_fftwf_init_threads" = xyes; then :
  acx_fftwt_ok=yes
else
  acx_fftwt_ok=no
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13571

13572
        if test x$acx_fftwt_ok = xyes; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13573

13574
$as_echo "#define HAVE_FFTWF_MP 1" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13575

13576
13577
13578
13579
13580
13581
13582
13583
13584
13585
13586
          FFTW_LIBS="-lfftw3f"
        else
          { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fftwf_init_threads in -lfftw3f_threads" >&5
$as_echo_n "checking for fftwf_init_threads in -lfftw3f_threads... " >&6; }
if ${ac_cv_lib_fftw3f_threads_fftwf_init_threads+:} false; then :
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lfftw3f_threads -lfftw3f -lm -lpthread $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h.  */
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13587

13588
13589
13590
13591
13592
13593
13594
13595
13596
13597
13598
13599
13600
13601
13602
13603
13604
13605
13606
13607
13608
13609
13610
13611
13612
13613
13614
13615
13616
13617
13618
/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char fftwf_init_threads ();
int
main ()
{
return fftwf_init_threads ();
  ;
  return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
  ac_cv_lib_fftw3f_threads_fftwf_init_threads=yes
else
  ac_cv_lib_fftw3f_threads_fftwf_init_threads=no
fi
rm -f core conftest.err conftest.$ac_objext \
    conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fftw3f_threads_fftwf_init_threads" >&5
$as_echo "$ac_cv_lib_fftw3f_threads_fftwf_init_threads" >&6; }
if test "x$ac_cv_lib_fftw3f_threads_fftwf_init_threads" = xyes; then :
  acx_fftwt_ok=yes
else
  acx_fftwt_ok=no
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13619

13620
          if test x$acx_fftwt_ok = xyes; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13621

13622
$as_echo "#define HAVE_FFTWF_MP 1" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13623

13624
13625
13626
            FFTW_LIBS="-lfftw3f_threads -lfftw3f"
          else
            FFTW_WARN="FFTW single precision library was compiled without multithreading support!"
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13627

13628
13629
13630
13631
13632
13633
13634
13635
13636
13637
13638
13639
          fi
        fi
      else
        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fftw_init_threads in -lfftw3" >&5
$as_echo_n "checking for fftw_init_threads in -lfftw3... " >&6; }
if ${ac_cv_lib_fftw3_fftw_init_threads+:} false; then :
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lfftw3 -lm -lpthread $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h.  */
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13640

13641
13642
13643
13644
13645
13646
13647
13648
13649
13650
13651
13652
13653
13654
13655
13656
13657
/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char fftw_init_threads ();
int
main ()
{
return fftw_init_threads ();
  ;
  return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
  ac_cv_lib_fftw3_fftw_init_threads=yes
13658
else
13659
  ac_cv_lib_fftw3_fftw_init_threads=no
13660
fi
13661
13662
13663
13664
13665
13666
13667
13668
13669
13670
rm -f core conftest.err conftest.$ac_objext \
    conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fftw3_fftw_init_threads" >&5
$as_echo "$ac_cv_lib_fftw3_fftw_init_threads" >&6; }
if test "x$ac_cv_lib_fftw3_fftw_init_threads" = xyes; then :
  acx_fftwt_ok=yes
else
  acx_fftwt_ok=no
13671
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13672

13673
        if test x$acx_fftwt_ok = xyes; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13674

13675
$as_echo "#define HAVE_FFTW_MP 1" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13676

13677
13678
13679
13680
13681
13682
13683
13684
13685
13686
13687
          FFTW_LIBS="-lfftw3"
        else
          { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fftw_init_threads in -lfftw3_threads" >&5
$as_echo_n "checking for fftw_init_threads in -lfftw3_threads... " >&6; }
if ${ac_cv_lib_fftw3_threads_fftw_init_threads+:} false; then :
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lfftw3_threads -lfftw3 -lm -lpthread $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h.  */
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13688

13689
13690
13691
13692
13693
13694
13695
13696
13697
13698
13699
13700
13701
13702
13703
13704
13705
13706
13707
13708
13709
13710
13711
13712
13713
13714
13715
13716
13717
13718
13719
/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char fftw_init_threads ();
int
main ()
{
return fftw_init_threads ();
  ;
  return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
  ac_cv_lib_fftw3_threads_fftw_init_threads=yes
else
  ac_cv_lib_fftw3_threads_fftw_init_threads=no
fi
rm -f core conftest.err conftest.$ac_objext \
    conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fftw3_threads_fftw_init_threads" >&5
$as_echo "$ac_cv_lib_fftw3_threads_fftw_init_threads" >&6; }
if test "x$ac_cv_lib_fftw3_threads_fftw_init_threads" = xyes; then :
  acx_fftwt_ok=yes
else
  acx_fftwt_ok=no
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13720

13721
          if test x$acx_fftwt_ok = xyes; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13722

13723
$as_echo "#define HAVE_FFTW_MP 1" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13724

13725
13726
13727
            FFTW_LIBS="-lfftw3_threads -lfftw3"
          else
            FFTW_WARN="FFTW double precision library was compiled without multithreading support!"
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13728

13729
13730
13731
13732
13733
13734
13735
13736
13737
13738
13739
13740
13741
13742
13743
          fi
        fi
      fi
    fi
  else
    if test xyes = xyes; then
      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fftwf_execute in -lfftw3f" >&5
$as_echo_n "checking for fftwf_execute in -lfftw3f... " >&6; }
if ${ac_cv_lib_fftw3f_fftwf_execute+:} false; then :
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lfftw3f -L$with_fftw_libdir -lm $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h.  */
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13744

13745
13746
13747
13748
13749
13750
13751
13752
13753
13754
13755
13756
13757
13758
13759
13760
13761
13762
13763
13764
13765
13766
13767
13768
13769
13770
13771
13772
13773
13774
13775
/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char fftwf_execute ();
int
main ()
{
return fftwf_execute ();
  ;
  return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
  ac_cv_lib_fftw3f_fftwf_execute=yes
else
  ac_cv_lib_fftw3f_fftwf_execute=no
fi
rm -f core conftest.err conftest.$ac_objext \
    conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fftw3f_fftwf_execute" >&5
$as_echo "$ac_cv_lib_fftw3f_fftwf_execute" >&6; }
if test "x$ac_cv_lib_fftw3f_fftwf_execute" = xyes; then :
  acx_fftw_ok=yes
else
  acx_fftw_ok=no
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13776

13777
      if test x$acx_fftw_ok = xyes; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13778

13779
$as_echo "#define HAVE_FFTWF 1" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13780

13781
13782
13783
13784
13785
13786
13787
13788
13789
13790
13791
13792
13793
13794
        FFTW_LIBS="-L$with_fftw_libdir -lfftw3f"
      else
        FFTW_ERROR="FFTW single precision library files not found in $with_fftw_libdir!"
      fi
    else
      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fftw_execute in -lfftw3" >&5
$as_echo_n "checking for fftw_execute in -lfftw3... " >&6; }
if ${ac_cv_lib_fftw3_fftw_execute+:} false; then :
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lfftw3 -L$with_fftw_libdir -lm $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h.  */
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13795

13796
13797
13798
13799
13800
13801
13802
13803
13804
13805
13806
13807
13808
13809
13810
13811
13812
13813
13814
13815
13816
13817
13818
13819
13820
13821
13822
13823
13824
13825
13826
/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char fftw_execute ();
int
main ()
{
return fftw_execute ();
  ;
  return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
  ac_cv_lib_fftw3_fftw_execute=yes
else
  ac_cv_lib_fftw3_fftw_execute=no
fi
rm -f core conftest.err conftest.$ac_objext \
    conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fftw3_fftw_execute" >&5
$as_echo "$ac_cv_lib_fftw3_fftw_execute" >&6; }
if test "x$ac_cv_lib_fftw3_fftw_execute" = xyes; then :
  acx_fftw_ok=yes
else
  acx_fftw_ok=no
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13827

13828
      if test x$acx_fftw_ok = xyes; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13829

13830
$as_echo "#define HAVE_FFTW 1" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13831

13832
13833
13834
13835
13836
13837
13838
13839
13840
13841
13842
13843
13844
13845
13846
13847
        FFTW_LIBS="-L$with_fftw_libdir -lfftw3"
      else
        FFTW_ERROR="FFTW double precision library files not found in $with_fftw_libdir!"
      fi
    fi
    if test x$acx_fftw_ok = xyes && test x$use_pthreads = xyes; then
      if test xyes = xyes; then
        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fftwf_init_threads in -lfftw3f" >&5
$as_echo_n "checking for fftwf_init_threads in -lfftw3f... " >&6; }
if ${ac_cv_lib_fftw3f_fftwf_init_threads+:} false; then :
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lfftw3f -L$with_fftw_libdir -lm -lpthread $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h.  */
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13848

13849
13850
13851
13852
13853
13854
13855
13856
13857
13858
13859
13860
13861
13862
13863
13864
13865
13866
13867
13868
13869
13870
13871
13872
13873
13874
13875
13876
13877
13878
13879
/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char fftwf_init_threads ();
int
main ()
{
return fftwf_init_threads ();
  ;
  return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
  ac_cv_lib_fftw3f_fftwf_init_threads=yes
else
  ac_cv_lib_fftw3f_fftwf_init_threads=no
fi
rm -f core conftest.err conftest.$ac_objext \
    conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fftw3f_fftwf_init_threads" >&5
$as_echo "$ac_cv_lib_fftw3f_fftwf_init_threads" >&6; }
if test "x$ac_cv_lib_fftw3f_fftwf_init_threads" = xyes; then :
  acx_fftwt_ok=yes
else
  acx_fftwt_ok=no
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13880

13881
        if test x$acx_fftwt_ok = xyes; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13882

13883
$as_echo "#define HAVE_FFTWF_MP 1" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13884

13885
13886
13887
13888
13889
13890
13891
13892
13893
13894
13895
          FFTW_LIBS="-L$with_fftw_libdir -lfftw3f"
        else
          { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fftwf_init_threads in -lfftw3f_threads" >&5
$as_echo_n "checking for fftwf_init_threads in -lfftw3f_threads... " >&6; }
if ${ac_cv_lib_fftw3f_threads_fftwf_init_threads+:} false; then :
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lfftw3f_threads -L$with_fftw_libdir -lfftw3f -lm -lpthread $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h.  */
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13896

13897
13898
13899
13900
13901
13902
13903
13904
13905
13906
13907
13908
13909
13910
13911
13912
13913
13914
13915
13916
13917
13918
13919
13920
13921
13922
13923
13924
13925
13926
13927
/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char fftwf_init_threads ();
int
main ()
{
return fftwf_init_threads ();
  ;
  return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
  ac_cv_lib_fftw3f_threads_fftwf_init_threads=yes
else
  ac_cv_lib_fftw3f_threads_fftwf_init_threads=no
fi
rm -f core conftest.err conftest.$ac_objext \
    conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fftw3f_threads_fftwf_init_threads" >&5
$as_echo "$ac_cv_lib_fftw3f_threads_fftwf_init_threads" >&6; }
if test "x$ac_cv_lib_fftw3f_threads_fftwf_init_threads" = xyes; then :
  acx_fftwt_ok=yes
else
  acx_fftwt_ok=no
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13928

13929
          if test x$acx_fftwt_ok = xyes; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13930

13931
$as_echo "#define HAVE_FFTWF_MP 1" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13932

13933
13934
13935
            FFTW_LIBS="-L$with_fftw_libdir -lfftw3f_threads -lfftw3f"
          else
            FFTW_WARN="FFTW single precision library in $with_fftw_libdir was compiled without multithreading support!"
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13936

13937
13938
13939
13940
13941
13942
13943
13944
13945
13946
13947
13948
          fi
        fi
      else
        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fftw_init_threads in -lfftw3_threads" >&5
$as_echo_n "checking for fftw_init_threads in -lfftw3_threads... " >&6; }
if ${ac_cv_lib_fftw3_threads_fftw_init_threads+:} false; then :
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lfftw3_threads -L$with_fftw_libdir -lfftw3 -lm -lpthread $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h.  */
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13949

13950
13951
13952
13953
13954
13955
13956
13957
13958
13959
13960
13961
13962
13963
13964
13965
13966
13967
13968
13969
13970
13971
13972
13973
13974
13975
13976
13977
13978
13979
13980
/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char fftw_init_threads ();
int
main ()
{
return fftw_init_threads ();
  ;
  return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
  ac_cv_lib_fftw3_threads_fftw_init_threads=yes
else
  ac_cv_lib_fftw3_threads_fftw_init_threads=no
fi
rm -f core conftest.err conftest.$ac_objext \
    conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fftw3_threads_fftw_init_threads" >&5
$as_echo "$ac_cv_lib_fftw3_threads_fftw_init_threads" >&6; }
if test "x$ac_cv_lib_fftw3_threads_fftw_init_threads" = xyes; then :
  acx_fftwt_ok=yes
else
  acx_fftwt_ok=no
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13981

13982
        if test x$acx_fftwt_ok = xyes; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13983

13984
$as_echo "#define HAVE_FFTW_MP 1" >>confdefs.h
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13985

13986
13987
13988
          FFTW_LIBS="-L$with_fftw_libdir -lfftw3_threads -lfftw3"
        else
          FFTW_WARN="FFTW double precision library in $with_fftw_libdir was compiled without multithreading support!"
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13989

13990
13991
13992
13993
13994
        fi
      fi
    fi
  fi
fi
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13995

13996
13997
LIBS="$OLIBS"
if test x$acx_fftw_ok = xyes; then
Emmanuel Bertin's avatar
Emmanuel Bertin committed
13998

13999
14000
  LIBS="$FFTW_LIBS $LIBS"
	if test "$FFTW_WARN" != ""; then
For faster browsing, not all history is shown. View entire blame