From a5d2c704eb44386c379ee4b4dda75fe65e364d74 Mon Sep 17 00:00:00 2001 From: Sergiu Deitsch Date: Sun, 14 Jul 2024 17:38:13 +0200 Subject: [PATCH] cmake: do not duplicate libm --- CMakeLists.txt | 4 ++-- CXSparse/CMakeLists.txt | 14 +++++++------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 675028903..28b5d8d00 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,7 +1,7 @@ # # CMake support layer for SuiteSparse # -# Copyright 2023 Sergiu Deitsch +# Copyright 2024 Sergiu Deitsch # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ # limitations under the License. # -cmake_minimum_required (VERSION 3.22) +cmake_minimum_required (VERSION 3.22...3.29) if (NOT DEFINED CMAKE_CUDA_ARCHITECTURES) set (CMAKE_CUDA_ARCHITECTURES 75) diff --git a/CXSparse/CMakeLists.txt b/CXSparse/CMakeLists.txt index 84198b626..fe5b7c3b7 100644 --- a/CXSparse/CMakeLists.txt +++ b/CXSparse/CMakeLists.txt @@ -1,7 +1,7 @@ # # CMake support layer for SuiteSparse # -# Copyright 2016-2021 Sergiu Deitsch +# Copyright 2024 Sergiu Deitsch # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -16,7 +16,7 @@ # limitations under the License. # -cmake_minimum_required (VERSION 3.12) +cmake_minimum_required (VERSION 3.12..3.30) project (cxsparse LANGUAGES C VERSION 3.2.0 DESCRIPTION "A Concise Sparse matrix package - Extended" HOMEPAGE_URL http://faculty.cse.tamu.edu/davis/suitesparse.html @@ -221,7 +221,7 @@ target_include_directories (cxsparse PUBLIC ) if (HAVE_M) - target_link_libraries (cxsparse PRIVATE m) + target_link_libraries (cxsparse PUBLIC m) endif (HAVE_M) if (NOT HAVE_C99_COMPLEX STREQUAL "") @@ -282,13 +282,13 @@ add_executable (cs_ci_demo2 $ Demo/cs_ci_demo2.c ) -target_link_libraries (cs_ci_demo2 PRIVATE cxsparse $<$:m>) +target_link_libraries (cs_ci_demo2 PRIVATE cxsparse) add_executable (cs_ci_demo3 $ Demo/cs_ci_demo3.c ) -target_link_libraries (cs_ci_demo3 PRIVATE cxsparse $<$:m>) +target_link_libraries (cs_ci_demo3 PRIVATE cxsparse) add_executable (cs_cl_demo1 Demo/cs_cl_demo1.c @@ -306,13 +306,13 @@ add_executable (cs_cl_demo2 $ Demo/cs_cl_demo2.c ) -target_link_libraries (cs_cl_demo2 PRIVATE cxsparse $<$:m>) +target_link_libraries (cs_cl_demo2 PRIVATE cxsparse) add_executable (cs_cl_demo3 $ Demo/cs_cl_demo3.c ) -target_link_libraries (cs_cl_demo3 PRIVATE cxsparse $<$:m>) +target_link_libraries (cs_cl_demo3 PRIVATE cxsparse) add_executable (cs_di_demo1 Demo/cs_di_demo1.c