From 9dd4f5fc05412f9702a6065ce32c9da4c66b6749 Mon Sep 17 00:00:00 2001 From: Iñaki Úcar Date: Aug 16 2020 12:00:07 +0000 Subject: https://fedoraproject.org/wiki/Changes/FlexiBLAS_as_BLAS/LAPACK_manager --- diff --git a/root-add-flexiblas-detection.patch b/root-add-flexiblas-detection.patch new file mode 100644 index 0000000..bcf8063 --- /dev/null +++ b/root-add-flexiblas-detection.patch @@ -0,0 +1,31 @@ +From 2f3c530cd8c8b9adc0303e2ae24a069f671aee1c Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?I=C3=B1aki=20=C3=9Acar?= +Date: Sun, 16 Aug 2020 13:46:21 +0200 +Subject: [PATCH] add flexiblas detection + +--- + cmake/modules/SearchInstalledSoftware.cmake | 8 +++++++- + 1 file changed, 7 insertions(+), 1 deletion(-) + +diff --git a/cmake/modules/SearchInstalledSoftware.cmake b/cmake/modules/SearchInstalledSoftware.cmake +index f1c6ee27..12aa822f 100644 +--- a/cmake/modules/SearchInstalledSoftware.cmake ++++ b/cmake/modules/SearchInstalledSoftware.cmake +@@ -1496,7 +1496,13 @@ endif() + if(tmva) + if(tmva-cpu AND imt) + message(STATUS "Looking for BLAS for optional parts of TMVA") +- find_package(BLAS) ++ pkg_check_modules(FLEXIBLAS flexiblas) ++ set(BLAS_FOUND ${FLEXIBLAS_FOUND}) ++ set(BLAS_LIBRARIES "${FLEXIBLAS_LIBRARIES}") ++ set(BLAS_LINKER_FLAGS) ++ if (NOT BLAS_FOUND) ++ find_package(BLAS) ++ endif() + if(NOT BLAS_FOUND) + if (GSL_FOUND) + message(STATUS "Using GSL CBLAS for optional parts of TMVA") +-- +2.25.2 + diff --git a/root.spec b/root.spec index fd2d1be..75dba66 100644 --- a/root.spec +++ b/root.spec @@ -30,6 +30,12 @@ %global tbb 0 %endif +%if 0%{?fedora} >= 33 +%global blaslib flexiblas +%else +%global blaslib blas +%endif + # Do not create .orig files when patching source %global _default_patch_flags --no-backup-if-mismatch @@ -39,7 +45,7 @@ Name: root Version: 6.22.00 %global libversion %(cut -d. -f 1-2 <<< %{version}) -Release: 5%{?dist} +Release: 6%{?dist} Summary: Numerical data analysis framework License: LGPLv2+ @@ -139,6 +145,8 @@ Patch31: %{name}-fix-bad-regex.patch # Compatibility with xrootd 5 # https://github.com/root-project/root/pull/6031 Patch32: %{name}-xrootd5-compat.patch +# Enable FlexiBLAS detection +Patch33: %{name}-add-flexiblas-detection.patch # s390x suffers from endian issues resulting in failing tests # and broken documentation generation @@ -217,7 +225,7 @@ BuildRequires: gcc-gfortran BuildRequires: graphviz-devel BuildRequires: expat-devel BuildRequires: pythia8-devel >= 8.1.80 -BuildRequires: blas-devel +BuildRequires: %{blaslib}-devel BuildRequires: python%{python3_pkgversion}-numpy BuildRequires: doxygen BuildRequires: graphviz @@ -1839,6 +1847,7 @@ This package contains an ntuple extension for ROOT 7. %patch30 -p1 %patch31 -p1 %patch32 -p1 +%patch33 -p1 # Remove bundled sources in order to be sure they are not used # * afterimage @@ -3464,6 +3473,9 @@ fi %endif %changelog +* Sun Aug 16 2020 Iñaki Úcar - 6.22.00-6 +- https://fedoraproject.org/wiki/Changes/FlexiBLAS_as_BLAS/LAPACK_manager + * Tue Aug 11 2020 Mattias Ellert - 6.22.00-5 - Fix wrong symlinks in EPEL 7 python2-root package