Changeset 1914
- Timestamp:
- Apr 24, 2009, 7:52:09 PM (14 years ago)
- Location:
- trunk
- Files:
-
- 1 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/build_support/yat-config.in
r1898 r1914 40 40 41 41 if test "x$YAT_CBLAS_LIB" = "x"; then 42 YAT_CBLAS_LIB= @YAT_CBLAS_LIB@42 YAT_CBLAS_LIB="@YAT_CBLAS_LIB@" 43 43 fi 44 44 -
trunk/configure.ac
r1897 r1914 125 125 AC_MSG_NOTICE([checking for libraries]) 126 126 AC_CHECK_LIBM 127 AS_IF([test "x$LIBM" != x], [LIBS="$LIBM $LIBS"]) 128 # searching for cblas. Priority 1) find a cblas library, 2) find ATLAS 129 # generated cblas, and 3) fall back to GSL cblas implementation. If 130 # partial ATLAS is detected the configure script fails. 131 cblas_found="no" # cblas_found may get values yes or no 132 # atlas_found may get values yes, no, or partial. In some cases 133 # partial atlas may be installed 134 atlas_found="no" 135 gslcblas_found="no" # gslcblas_found may get values yes or no 136 AC_SEARCH_LIBS(cblas_sdsdot,cblas,cblas_found="yes", 137 AC_SEARCH_LIBS(ATL_sdsdot,atlas, 138 AC_SEARCH_LIBS(cblas_sdsdot,cblas,atlas_found="yes", 139 atlas_found="partial",-m64), 140 AC_SEARCH_LIBS(cblas_dswap,gslcblas,gslcblas_found="yes"),-m64),) 141 142 YAT_CBLAS_LIB=-lgslcblas 143 if test ${cblas_found} = "yes"; then 144 YAT_CBLAS_LIB=-lcblas 145 fi 146 if test ${atlas_found} = "yes"; then 147 YAT_CXX_ADD_FLAG([CXXFLAGS], [-m64]) 148 YAT_LD_ADD_FLAG([LDFLAGS], [-m64]) 149 YAT_CBLAS_LIB=-latlas 150 fi 151 # used in test of gsl 152 export GSL_CBLAS_LIB=${YAT_CBLAS_LIB} 153 AC_SUBST(YAT_CBLAS_LIB) 154 127 128 ACX_BLAS([YAT_CBLAS_LIB=$BLAS_LIBS], [YAT_CBLAS_LIB=-lgslcblas]) 155 129 156 130 # GNU Scientific Library, GSL http://www.gnu.org/software/gsl/, checks … … 158 132 gsl_version="1.8" 159 133 AC_SUBST(gsl_version) 160 # sets variable $yat_gsl_status to one of the following 161 # "ok" - everything is fine 162 # "no" - no gsl found 163 # "no-header" - gsl library found but no header files 164 # "old" - gsl older than $gsl_version found 165 YAT_CHECK_GSL([$gsl_version]) 134 gsl_ok=yes 135 YAT_CHECK_GSL([$gsl_version],[gsl_ok=yes]) 166 136 167 137 # Boost http://www.boost.org … … 368 338 369 339 # Non-existing GSL is fatal -- sub-sequent compilation will fail. 370 if test "x$yat_gsl_status" != "xok" ; then 371 all_reqs_ok="false" 372 AS_CASE([$yat_gsl_status], 373 [old], 374 [AC_MSG_WARN([ 375 GSL found but not the required version. Please install 376 GSL version ${gsl_version} or later]) 377 ], 378 [no-header], 379 [AC_MSG_WARN([ 380 GSL header files not found. The GNU Scientific Library (GSL) 381 header files cannot be found. Please make sure GSL header 382 files are installed.]) 383 ], 384 [AC_MSG_WARN([ 385 GSL not found. The GNU Scientific Library (GSL) library cannot be 386 found. Please make sure GSL is installed.]) 387 ]) 340 if test "x$gsl_ok" != "xyes" ; then 341 all_reqs_ok="false" 342 AC_MSG_WARN([ 343 GSL $gsl_version (or newer) not found. The GNU 344 Scientific Library (GSL) library cannot be found. Please 345 make sure GSL is installed. Please refer to warnings 346 above for more details 347 ]) 388 348 fi 389 349 … … 408 368 APR_RESTORE_THE_ENVIRONMENT(CXXFLAGS, YAT_) 409 369 APR_RESTORE_THE_ENVIRONMENT(LDFLAGS, YAT_) 410 APR_RESTORE_THE_ENVIRONMENT(LIBS, YAT_PRIMARY_) 411 412 # remove cblas and m 413 APR_REMOVEFROM([YAT_PRIMARY_LIBS], [$YAT_CBLAS_LIB]) 414 APR_REMOVEFROM([YAT_PRIMARY_LIBS], [$LIBM]) 415 370 371 YAT_PRIMARY_LIBS=-lgsl 416 372 YAT_LIBS="$YAT_PRIMARY_LIBS $YAT_CBLAS_LIB $LIBM" 373 AC_SUBST(YAT_PRIMARY_LIBS) 417 374 AC_SUBST(YAT_LIBS) 375 AC_SUBST(YAT_CBLAS_LIB) 418 376 419 377 # set and AC_SUBST variables that are interpreted by Automake -
trunk/m4/yat_gsl.m4
r1895 r1914 38 38 ]) 39 39 40 # check if failure was due to too old gsl41 AS_IF([test "x$yat_gsl_status" = "xno" && \42 test -f "$GSL_CONFIG" && $GSL_CONFIG --help >/dev/null 2>&1],43 [yat_gsl_status="old"44 ])45 46 # if everything is fine, append to gsl variables to LIBS and friends47 40 AS_IF([test "x$yat_gsl_status" = "xok"], 48 [LIBS="-lgsl $LIBS" 49 # grep words starting with '-L' in other words LDFLAGS 41 [# grep words startinging with '-L' in other words LDFLAGS 50 42 for i in $GSL_LIBS; do 51 43 AS_IF([test ${i:0:2} = "-L"], 52 44 [YAT_LD_ADD_FLAG([LDFLAGS], [$i])]) 53 done 45 done 54 46 ]) 47 48 55 49 56 50 ]) # YAT_CHECK_GSL
Note: See TracChangeset
for help on using the changeset viewer.