- adjust for hpc build on SLE (scotch/ptscotch), but without CGAL

OBS-URL: https://build.opensuse.org/package/show/science/openfoam?expand=0&rev=26
This commit is contained in:
Mark Olesen
2021-06-30 12:26:33 +00:00
committed by Git OBS Bridge
parent 95027844f0
commit 8c2053712b
3 changed files with 45 additions and 11 deletions
+5
View File
@@ -1,3 +1,8 @@
-------------------------------------------------------------------
Wed Jun 30 12:10:43 UTC 2021 - Mark.Olesen@esi-group.com
- adjust for hpc build on SLE (scotch/ptscotch), but without CGAL
-------------------------------------------------------------------
Fri Jun 25 11:18:22 UTC 2021 - Mark.Olesen@esi-group.com
+38 -9
View File
@@ -23,10 +23,9 @@
%define tar_filename OpenFOAM-v%{foam_api}.tgz
%endif
# Enable cgal, scotch, ptscotch by default (like bcond_without)
%global with_cgal 1
%global with_scotch 1
%global with_ptscotch 1
# Enable scotch, ptscotch by default
%bcond_without scotch
%bcond_without ptscotch
# Enable openfoam-selector for openSUSE (part of the science repo)
%if 0%{?suse_version}
@@ -35,6 +34,7 @@
%bcond_with foam_selector
%endif
# Basic hpc build - currently only openmpi
%global mpi_family openmpi
@@ -49,6 +49,23 @@
%define mpi_ext %{?mpi_vers}
%endif
# ------------------
# SLE: cgal does not exist, or hard to find
# SLE: scotch packaged as gnu-xxx-hpc
# RedHat: cgal seems to be a problem
%if !0%{?is_opensuse} && 0%{?sle_version}
%bcond_with cgal
%bcond_without hpc
%define hpc_mpi_package gnu-%{mpi_family}%{?mpi_vers}-hpc
%else
%bcond_with hpc
%if 0%{?fedora}%{?suse_version}
%bcond_without cgal
%else
%bcond_with cgal
%endif
%endif
# ------------------
Name: openfoam%{foam_api}
@@ -111,16 +128,28 @@ BuildRequires: cmake(CGAL)
%endif
%endif
#</with-cgal>
%if %{with scotch}
%if %{with scotch} && !%{with hpc}
BuildRequires: scotch-devel
%endif
# This needs better sorting out
# - openSUSE (non-hpc):
# ptscotch-openmpi2-devel, libptscotch0-openmpi2
# - SUSE (-hpc):
# ptscotch-gnu-openmpi2-hpc-devel, libptscotch-gnu-openmpi2-hpc
# - RedHat
# ptscotch-openmpi2-devel, libptscotch-openmpi2
%if %{with ptscotch}
%if %{with hpc}
BuildRequires: ptscotch-%{hpc_mpi_package}-devel
Requires: libptscotch-%{hpc_mpi_package}
%else # hpc
BuildRequires: ptscotch-%{mpi_family}%{?mpi_ext}-devel
%if 0%{?fedora}%{?rhel}
%if 0%{?fedora}%{?rhel}
Requires: ptscotch-%{mpi_family}%{?mpi_ext}
%else
%else # redhat
Requires: libptscotch0-%{mpi_family}%{?mpi_ext}
%endif
%endif
%endif
%endif
@@ -219,7 +248,7 @@ OpenFOAM is a free, open source computational fluid dynamics (CFD)
software package produced by OpenCFD Ltd with twice yearly releases.}
%global _description2 %{expand:
* Release notes: https://www.openfoam.com/releases/openfoam-v%{foam_api}
* Release notes: https://www.openfoam.com/news/main-news/openfoam-v%{foam_api}
* Documentation: https://www.openfoam.com/documentation/
* Issue Tracker: https://develop.openfoam.com/Development/openfoam/issues/}
+2 -2
View File
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:ec1597570034a7b757fba0566e9317d4fb693233b82a9432c80c54945330b6a5
size 65969387
oid sha256:6ef0714ef841779bad346a21247fb352853ab8923b775a3678c7087bee1087ca
size 65968881