From 34bc8e62e59efaf9242485a31f7b760bed602c6d Mon Sep 17 00:00:00 2001 From: Nicklas Larsson Date: Fri, 30 Aug 2024 13:34:46 +0200 Subject: [PATCH] debug 4 --- configure | 29 +++++++++++++++++++---------- configure.ac | 19 ++++++++++++++----- 2 files changed, 33 insertions(+), 15 deletions(-) diff --git a/configure b/configure index 90b2b2dc609..9aab3d7d6e1 100755 --- a/configure +++ b/configure @@ -13793,6 +13793,7 @@ done { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for linking to BLAS" >&5 printf %s "checking for linking to BLAS... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ char cblas_dgemm(); @@ -13817,44 +13818,52 @@ rm -f core conftest.err conftest.$ac_objext conftest.beam \ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $blas_ok" >&5 printf "%s\n" "$blas_ok" >&6; } - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for linking to BLAS sgemm" >&5 -printf %s "checking for linking to BLAS sgemm... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for linking to BLAS dgemm" >&5 +printf %s "checking for linking to BLAS dgemm... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - +char sgemm(); int main (void) { -sgemm +return sgemm(); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : - blas_ok=yes; + blas_ok=yes +else $as_nop + + + fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $blas_ok" >&5 printf "%s\n" "$blas_ok" >&6; } - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for linking to BLAS cblas_dgemm" >&5 -printf %s "checking for linking to BLAS cblas_dgemm... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for linking to BLAS dgemm" >&5 +printf %s "checking for linking to BLAS dgemm... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - +char sgemm(); int main (void) { -cblas_dgemm +return dgemm(); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO" then : - blas_ok=yes; + blas_ok=yes +else $as_nop + + + fi rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext diff --git a/configure.ac b/configure.ac index f1f638d003b..582fb2b6a22 100644 --- a/configure.ac +++ b/configure.ac @@ -1628,6 +1628,7 @@ dnl [[char cblas_dgemm();]], [[return cblas_dgemm();]])], dnl [blas_ok=yes] , [ dnl AC_MSG_ERROR([*** Unable to link to BLAS library with "$BLASLIB".]) dnl ]) + AC_LINK_IFELSE([AC_LANG_PROGRAM( [[char cblas_dgemm();]], [[return cblas_dgemm();]])], [blas_ok=yes] , [ @@ -1635,12 +1636,20 @@ dnl ]) ]) AC_MSG_RESULT($blas_ok) - AC_MSG_CHECKING([for linking to BLAS sgemm]) - AC_LINK_IFELSE([AC_LANG_PROGRAM([[]], [[sgemm]])],[blas_ok=yes;], []) - AC_MSG_RESULT([$blas_ok]) + AC_MSG_CHECKING([for linking to BLAS dgemm]) + AC_LINK_IFELSE([AC_LANG_PROGRAM( + [[char sgemm();]], [[return sgemm();]])], + [blas_ok=yes] , [ + [] + ]) + AC_MSG_RESULT($blas_ok) - AC_MSG_CHECKING([for linking to BLAS cblas_dgemm]) - AC_LINK_IFELSE([AC_LANG_PROGRAM([[]], [[cblas_dgemm]])],[blas_ok=yes;], []) + AC_MSG_CHECKING([for linking to BLAS dgemm]) + AC_LINK_IFELSE([AC_LANG_PROGRAM( + [[char sgemm();]], [[return dgemm();]])], + [blas_ok=yes] , [ + [] + ]) AC_MSG_RESULT([$blas_ok]) CFLAGS="$save_CFLAGS"