blob: 6c919877cfd1bab7cce96e8d46158cfe543f229e [file] [log] [blame]
From f4009d1efccf571d229e89fab846b0d5873e7a5b Mon Sep 17 00:00:00 2001
From: Lars Wendler <polynomial-c@gentoo.org>
Date: Thu, 13 Feb 2020 13:12:45 +0100
Subject: [PATCH] Prefer pkgconfig in FindBLAS
---
Modules/FindBLAS.cmake | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/Modules/FindBLAS.cmake b/Modules/FindBLAS.cmake
index 9b6d09c2f9..c2af42468c 100644
--- a/Modules/FindBLAS.cmake
+++ b/Modules/FindBLAS.cmake
@@ -7,6 +7,10 @@ FindBLAS
Find Basic Linear Algebra Subprograms (BLAS) library
+Version modified for Gentoo Linux.
+If a valid PkgConfig configuration is found, this overrides and cancels
+all further checks.
+
This module finds an installed Fortran library that implements the
BLAS linear-algebra interface (see http://www.netlib.org/blas/).
@@ -107,6 +111,9 @@ if(NOT (CMAKE_C_COMPILER_LOADED OR CMAKE_CXX_COMPILER_LOADED OR CMAKE_Fortran_CO
endif()
endif()
+# first, try PkgConfig
+set(BLA_PREFER_PKGCONFIG On)
+
if(CMAKE_Fortran_COMPILER_LOADED)
include(${CMAKE_CURRENT_LIST_DIR}/CheckFortranFunctionExists.cmake)
else()
--
2.25.0