From cf413479ad1f6d5bfd4ef2a3d3f2a35b185371fb Mon Sep 17 00:00:00 2001 From: Michael Hirsch Date: Mon, 6 Dec 2021 00:03:18 -0500 Subject: [PATCH] cmake >= 3.19 --- .github/workflows/ci_windows.yml | 3 +-- CMakeLists.txt | 12 +++--------- cmake/Modules/FindSCALAPACK.cmake | 2 +- cmake/libraries.json | 2 +- cmake/options.cmake | 8 +++++++- codemeta.json | 2 +- 6 files changed, 14 insertions(+), 15 deletions(-) diff --git a/.github/workflows/ci_windows.yml b/.github/workflows/ci_windows.yml index ab57948..0c4d523 100644 --- a/.github/workflows/ci_windows.yml +++ b/.github/workflows/ci_windows.yml @@ -21,7 +21,6 @@ jobs: steps: - uses: actions/checkout@v2 - # GitHub Actions windows image doesn't have WSL, so use version without need to patch - - run: cmake -B build -Darith=d -Dparallel:BOOL=false "-DMUMPS_UPSTREAM_VERSION=5.3.5" + - run: cmake -B build -Darith=d -Dparallel:BOOL=false - run: cmake --build build - run: ctest --test-dir build --preset default diff --git a/CMakeLists.txt b/CMakeLists.txt index 07cba7a..a93a42d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.20...3.22) +cmake_minimum_required(VERSION 3.19...3.22) get_property(is_multi_config GLOBAL PROPERTY GENERATOR_IS_MULTI_CONFIG) if(NOT is_multi_config AND NOT (CMAKE_BUILD_TYPE OR DEFINED ENV{CMAKE_BUILD_TYPE})) @@ -15,16 +15,10 @@ DESCRIPTION "Sparse direct parallel solver" HOMEPAGE_URL "http://mumps-solver.org/" ) -include(CTest) +enable_testing() if(NOT MUMPS_UPSTREAM_VERSION) - set(MUMPS_UPSTREAM_VERSION 5.4.1) -endif() - -if(CMAKE_GENERATOR STREQUAL "Ninja Multi-Config") - set(EXTPROJ_GENERATOR "Ninja") -else() - set(EXTPROJ_GENERATOR ${CMAKE_GENERATOR}) + set(MUMPS_UPSTREAM_VERSION 5.3.5) endif() if(MSVC AND BUILD_SHARED_LIBS) diff --git a/cmake/Modules/FindSCALAPACK.cmake b/cmake/Modules/FindSCALAPACK.cmake index 1f2e6d8..a8bcf60 100644 --- a/cmake/Modules/FindSCALAPACK.cmake +++ b/cmake/Modules/FindSCALAPACK.cmake @@ -190,7 +190,7 @@ else() ) # some systems have libblacs as a separate file, instead of being subsumed in libscalapack. - cmake_path(GET SCALAPACK_LIBRARY PARENT_PATH BLACS_ROOT) + get_filename_component(BLACS_ROOT ${SCALAPACK_LIBRARY} DIRECTORY) find_library(BLACS_LIBRARY NAMES blacs diff --git a/cmake/libraries.json b/cmake/libraries.json index 21b26bc..90cf512 100644 --- a/cmake/libraries.json +++ b/cmake/libraries.json @@ -5,7 +5,7 @@ }, "scalapack": { "git": "https://github.com/scivision/scalapack.git", - "tag": "v2.1.0.29" + "tag": "v2.1.0.30" }, "mumps": { diff --git a/cmake/options.cmake b/cmake/options.cmake index 213b2e8..2520859 100644 --- a/cmake/options.cmake +++ b/cmake/options.cmake @@ -1,5 +1,5 @@ option(autobuild "auto-build Lapack and/or Scalapack if missing or broken" true) - +option(BUILD_TESTING "build with testing features" true) option(dev "developer mode") option(parallel "parallel or sequential (non-MPI, non-Scalapack)" ON) option(intsize64 "use 64-bit integers in C and Fortran" OFF) @@ -32,6 +32,12 @@ else() set_directory_properties(PROPERTIES EP_UPDATE_DISCONNECTED true) endif() +if(CMAKE_GENERATOR STREQUAL "Ninja Multi-Config") + set(EXTPROJ_GENERATOR "Ninja") +else() + set(EXTPROJ_GENERATOR ${CMAKE_GENERATOR}) +endif() + if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) # will not take effect without FORCE diff --git a/codemeta.json b/codemeta.json index f34ad60..26fe28f 100644 --- a/codemeta.json +++ b/codemeta.json @@ -8,7 +8,7 @@ "downloadUrl": "https://github.com/scivision/mumps/releases", "issueTracker": "https://github.com/scivision/mumps/issues", "name": "MUMPS", - "version": "5.4.1.8", + "version": "5.4.1.9", "identifier": "10.1145/3242094", "description": "MUltifrontal Massively Parallel sparse direct Solver", "applicationCategory": "linear algebra",