From d32356b567ce3b26f4710a86f23a954d84b423bc Mon Sep 17 00:00:00 2001 From: Billy Robert O'Neal III Date: Wed, 15 Oct 2025 13:30:02 -0700 Subject: [PATCH] [coin-or-*] Disable finding mkl, always use lapack.pc This removes explicit detection in coin-or-buildtools that started picking up intel-mkl.lib after https://github.com/microsoft/vcpkg/pull/47633 Related https://github.com/microsoft/vcpkg/pull/47764 --- ports/coin-or-buildtools/disable-mkl.diff | 60 +++++++++++++++++++++++ ports/coin-or-buildtools/portfile.cmake | 1 + ports/coin-or-buildtools/vcpkg.json | 1 + versions/baseline.json | 2 +- versions/c-/coin-or-buildtools.json | 5 ++ 5 files changed, 68 insertions(+), 1 deletion(-) create mode 100644 ports/coin-or-buildtools/disable-mkl.diff diff --git a/ports/coin-or-buildtools/disable-mkl.diff b/ports/coin-or-buildtools/disable-mkl.diff new file mode 100644 index 00000000000000..a9585757c636e6 --- /dev/null +++ b/ports/coin-or-buildtools/disable-mkl.diff @@ -0,0 +1,60 @@ +diff --git a/coin_chk_lapack.m4 b/coin_chk_lapack.m4 +index 3314f97..0156a0e 100644 +--- a/coin_chk_lapack.m4 ++++ b/coin_chk_lapack.m4 +@@ -113,55 +113,7 @@ dnl can arrange that explicitly. + esac + ;; + +- *-cygwin* | *-mingw* | *-msys*) +-dnl Check for 64-bit sequential MKL in $LIB +- old_IFS="$IFS" +- IFS=";" +- coin_mkl="" +- for d in $LIB ; do +- # turn $d into unix-style short path (no spaces); cannot do -us, +- # so first do -ws, then -u +- d=`cygpath -ws "$d"` +- d=`cygpath -u "$d"` +- if test "$enable_shared" = yes ; then +- if test -e "$d/mkl_core_dll.lib" ; then +- case " $2 " in +- *\ int64\ * ) coin_mkl="$d/mkl_intel_ilp64_dll.lib $d/mkl_sequential_dll.lib $d/mkl_core_dll.lib" ;; +- *) coin_mkl="$d/mkl_intel_lp64_dll.lib $d/mkl_sequential_dll.lib $d/mkl_core_dll.lib" ;; +- esac +- break +- fi +- else +- if test -e "$d/mkl_core.lib" ; then +- case " $2 " in +- *\ int64\ * ) coin_mkl="$d/mkl_intel_ilp64.lib $d/mkl_sequential.lib $d/mkl_core.lib" ;; +- *) coin_mkl="$d/mkl_intel_lp64.lib $d/mkl_sequential.lib $d/mkl_core.lib" ;; +- esac +- break +- fi +- fi +- done +- IFS="$old_IFS" +- if test -n "$coin_mkl" ; then +- AC_COIN_TRY_LINK([dsyev],[$coin_mkl],[], +- [coin_has_lapack=yes +- lapack_lflags="$coin_mkl" +- lapack_what="Intel MKL ($lapack_lflags)" +- ],,no) +- fi +- ;; +- + *-darwin*) +- case " $2 " in +- *\ int64\ * ) coin_mkl="-lmkl_intel_ilp64 -lmkl_sequential -lmkl_core -lm" ;; +- *) coin_mkl="-lmkl_intel_lp64 -lmkl_sequential -lmkl_core -lm" ;; +- esac +- AC_COIN_TRY_LINK([dsyev], +- [$coin_mkl],[], +- [coin_has_lapack=yes +- lapack_lflags="$coin_mkl" +- lapack_what="Intel MKL ($lapack_lflags)" +- ],,no) + if test "$coin_has_lapack" = no ; then + case " $2 " in + *\ int64\ * ) ;; diff --git a/ports/coin-or-buildtools/portfile.cmake b/ports/coin-or-buildtools/portfile.cmake index 1fb0db69c607c8..0eb1fa2ff4e863 100644 --- a/ports/coin-or-buildtools/portfile.cmake +++ b/ports/coin-or-buildtools/portfile.cmake @@ -7,6 +7,7 @@ vcpkg_from_github( SHA512 c142163a270848d1e1300a70713ee03ec822cc9d7583ba7aa685c02b7c25e0d4c0f7d958aad320dbf1824cc88fe0a49dc3357e0fe11588dc8c30e7fec8d239f6 PATCHES buildtools.patch buildtools2.patch + disable-mkl.diff ) file(COPY "${BUILD_SCRIPTS_PATH}/" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}/BuildTools") diff --git a/ports/coin-or-buildtools/vcpkg.json b/ports/coin-or-buildtools/vcpkg.json index e830313ce4e597..f8fa9a94097ddf 100644 --- a/ports/coin-or-buildtools/vcpkg.json +++ b/ports/coin-or-buildtools/vcpkg.json @@ -1,6 +1,7 @@ { "name": "coin-or-buildtools", "version-date": "2023-02-02", + "port-version": 1, "description": "Macros and patches for GNU autotools ", "homepage": "https://coin-or-tools.github.io/BuildTools/", "license": "EPL-2.0" diff --git a/versions/baseline.json b/versions/baseline.json index be4d864e2910bd..468768c5001749 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -1862,7 +1862,7 @@ }, "coin-or-buildtools": { "baseline": "2023-02-02", - "port-version": 0 + "port-version": 1 }, "coin-or-cbc": { "baseline": "2024-06-04", diff --git a/versions/c-/coin-or-buildtools.json b/versions/c-/coin-or-buildtools.json index 31566a047db5b9..6ce0c2cebbadbf 100644 --- a/versions/c-/coin-or-buildtools.json +++ b/versions/c-/coin-or-buildtools.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "9c512b1216f88b2c98a9944c43131fad4de9fdd5", + "version-date": "2023-02-02", + "port-version": 1 + }, { "git-tree": "b0d17057d8452f7e7fa4a3bfe6a2fab3520be6e9", "version-date": "2023-02-02",