Accepting request 674839 from home:eeich:branches:science

- Fix product groups.
- Fix dependencies.
- Consolidate use of openmpi1, openmpi2, openmpi3 for non-HPC builds.

OBS-URL: https://build.opensuse.org/request/show/674839
OBS-URL: https://build.opensuse.org/package/show/science/mumps?expand=0&rev=18
This commit is contained in:
Egbert Eich 2019-02-14 06:51:45 +00:00 committed by Git OBS Bridge
parent 706b34b517
commit ba129bd96d
2 changed files with 49 additions and 38 deletions

View File

@ -1,3 +1,10 @@
-------------------------------------------------------------------
Tue Feb 12 07:24:57 UTC 2019 - Egbert Eich <eich@suse.com>
- Fix product groups.
- Fix dependencies.
- Consolidate use of openmpi1, openmpi2, openmpi3 for non-HPC builds.
-------------------------------------------------------------------
Mon Feb 11 16:26:11 UTC 2019 - Egbert Eich <eich@suse.com>

View File

@ -56,12 +56,14 @@ ExclusiveArch: do_not_build
%if "%{flavor}" == "openmpi"
%define mpi_family openmpi
%define mumps_f77_mpilibs -lmpi_mpifh -lmpi
%define mpi_ver 1
%bcond_with hpc
%endif
%if "%{flavor}" == "openmpi2"
%define mpi_family openmpi2
%define mpi_family openmpi
%define mumps_f77_mpilibs -lmpi_mpifh -lmpi
%define mpi_ver 2
%bcond_with hpc
%endif
@ -79,14 +81,14 @@ ExclusiveArch: do_not_build
%endif
%if "%{flavor}" == "scotch-openmpi2"
%define mpi_family openmpi2
%define mpi_family openmpi
%define mumps_f77_mpilibs -lmpi_mpifh -lmpi
%bcond_with hpc
%bcond_without scotch
%endif
%if "%{flavor}" == "scotch-openmpi3"
%define mpi_family openmpi3
%define mpi_family openmpi
%define mumps_f77_mpilibs -lmpi_mpifh -lmpi
%bcond_with hpc
%bcond_without scotch
@ -160,6 +162,11 @@ ExclusiveArch: do_not_build
%{?mpi_family:%{bcond_without mpi}}%{!?mpi_family:%{bcond_with mpi}}
# For compatibility package names
%if "%{mpi_family}" != "openmpi" || "%{mpi_ver}" != "1"
%define mpi_ext %{?mpi_ver}
%endif
%if %{with scotch}
%if %{with mpi}
%define scotch ptscotch
@ -176,8 +183,8 @@ ExclusiveArch: do_not_build
%define my_incdir %_includedir
%define my_datadir %_datadir
%else
%define my_suffix -%{mpi_family}%{?mpi_ver}
%define my_prefix %{_libdir}/mpi/gcc/%{mpi_family}
%define my_suffix -%{mpi_family}%{?mpi_ext}
%define my_prefix %{_libdir}/mpi/gcc/%{mpi_family}%{?mpi_ext}
%define my_bindir %{my_prefix}/bin
%define my_libdir %{my_prefix}/%{_lib}/
%define my_incdir %{my_prefix}/include/
@ -187,10 +194,9 @@ ExclusiveArch: do_not_build
%define libname lib%{pname}%{?scotch:-%{scotch}}%{?so_ver}%{?my_suffix}
%else
%{!?compiler_family:%global compiler_family gnu}
%{?mpi_family:%{bcond_without mpi}}%{!?mpi_family:%{bcond_with mpi}}
%{?with_mpi:%{!?mpi_family:%global mpi_family openmpi}}
%{?with_mpi:%{!?mpi_family:error "No MPI family specified!"}}
%{hpc_init -c %compiler_family %{?c_f_ver:-v %{c_f_ver}} %{?with_mpi:-m {%mpi_family}} %{?mpi_ver:-V %{mpi_ver}} %{?scotch:-e %{scotch}}}
%define my_suffix -%{mpi_family}%{?mpi_ver}
%define my_prefix %{hpc_prefix}
%define my_bindir %{hpc_bindir}
%define my_libdir %{hpc_libdir}
@ -202,7 +208,7 @@ ExclusiveArch: do_not_build
Summary: A MUltifrontal Massively Parallel Sparse direct Solver
License: CECILL-C
Group: System/Libraries
Group: Productivity/Scientific/Math
Name: %{package_name}
Version: %{ver}
Release: 0
@ -212,15 +218,15 @@ Source1: Makefile.inc
Patch1: Makefiles-Serialize-libseq-libplat-mommond_mod-for-parallel-builds.patch
%if %{without hpc}
BuildRequires: gcc-fortran
%{?with_scotch:BuildRequires: %{scotch}%{?with_mpi:-%{mpi_family}}-devel}
%if %{with mpi}
BuildRequires: %{mpi_family}-devel
BuildRequires: scalapack-%{mpi_family}-devel
BuildRequires: libblacs2-%{mpi_family}-devel
%endif
%{?with_scotch:BuildRequires: %{scotch}%{?with_mpi:-%{mpi_family}%{?mpi_ext}}-devel}
%if %{with mpi}
BuildRequires: %{mpi_family}%{?mpi_ext}-devel
BuildRequires: scalapack-%{mpi_family}%{?mpi_ext}-devel
BuildRequires: libblacs2-%{mpi_family}%{?mpi_ext}-devel
%endif # mpi
BuildRequires: blas-devel
BuildRequires: lapack-devel
%else
%else # hpc
BuildRequires: %{compiler_family}%{?c_f_ver}-compilers-hpc-macros-devel
BuildRequires: %{mpi_family}%{?mpi_ver}-%{compiler_family}%{?c_f_ver}-hpc-macros-devel
BuildRequires: libscalapack2-%{compiler_family}-%{mpi_family}%{?mpi_ver}-hpc-devel
@ -228,7 +234,7 @@ BuildRequires: libblacs2-%{compiler_family}-%{mpi_family}%{?mpi_ver}-hpc-devel
BuildRequires: libgomp1
BuildRequires: suse-hpc
BuildRequires: fdupes
%endif
%endif # hpc
%description
MUMPS implements a direct solver for large sparse linear systems, with a
@ -239,7 +245,7 @@ C interfaces, and can interface with ordering tools such as Scotch.
%package -n %{libname}
Summary: A MUltifrontal Massively Parallel Sparse direct Solver
Group: System/Libraries
Group: Productivity/Scientific/Math
%if %{without hpc}
%{?with_mpi:Recommends: %{name}-%{so_ver}-compat = %{version}}
%else
@ -257,12 +263,12 @@ C interfaces, and can interface with ordering tools such as Scotch.
%if %{!with mpi}
This package contains the sequential library%{?scotch: with Scotch support enabled}.
%else
This package contains the parallel library%{?with_mpi: with %{mpi_family}}%{?scotch: with Scotch support enabled}.
This package contains the parallel library%{?with_mpi: with %{mpi_family}%{?mpi_ver}}%{?scotch: with Scotch support enabled}.
%endif
%package %{so_ver}-compat
Summary: A MUltifrontal Massively Parallel Sparse direct Solver
Group: System/Libraries
Group: Productivity/Scientific/Math
Requires: lib%{pname}%{?scotch:-scotch}%{so_ver} = %{version}
%if %{without hpc} && %{with mpi}
# Install link targets for non-HPC MPI compat links from the MPI libdir - see below.
@ -295,23 +301,23 @@ This package provides Documentation for %{package_name}.
%if %{!with mpi}
This package contains the sequential library%{?scotch: with Scotch support enabled}.
%else
This package contains the parallel library%{?with_mpi: with %{mpi_family}}%{?scotch: with Scotch support enabled}.
This package contains the parallel library%{?with_mpi: with %{mpi_family}%{?mpi_ver}}%{?scotch: with Scotch support enabled}.
%endif
%package devel
Summary: Files needed for developing mumps based applications
Group: Development/Libraries/Other
Group: Development/Libraries/Parallel
Requires: %{libname} = %version
%if %{without hpc}
%if %{with mpi} || %{with scotch}
Requires: mumps-devel = %{version}
%endif
%if %{with mpi}
Requires: %{mpi_family}-devel
Requires: scalapack-%{mpi_family}-devel
Requires: %{mpi_family}%{?mpi_ext}-devel
Requires: scalapack-%{mpi_family}%{?mpi_ext}-devel
%if %{with scotch}
Requires: mumps-scotch-devel = %{version}
Requires: ptscotch-%{mpi_family}-devel
Requires: ptscotch-%{mpi_family}%{?mpi_ext}-devel
%endif
%else # mpi
Requires: blas-devel
@ -334,7 +340,7 @@ Headers and development files for %{package_name}.
%package devel-static
Summary: Files needed for developing mumps based applications
Group: Development/Libraries/Other
Group: Development/Libraries/Parallel
Requires: %{package_name}-devel
%{?with_mpi:Recommends: %{name}-%{so_ver}-compat-static = %{version}}
@ -346,12 +352,12 @@ C interfaces, and can interface with ordering tools such as Scotch.
Static libraries for %{package_name}.
%package %{so_ver}-static-compat
%package devel-static-compat
Summary: Files needed for developing mumps based applications
Group: Development/Libraries/Other
Requires: lib%{pname}%{?scotch:-scotch}%{so_ver}-static = %version
Group: Development/Libraries/Parallel
Requires: %{pname}%{?scotch:-scotch}-devel-static = %version
%description %{so_ver}-static-compat
%description devel-static-compat
MUMPS implements a direct solver for large sparse linear systems, with a
particular focus on symmetric positive definite matrices. It can
operate on distributed matrices e.g. over a cluster. It has Fortran and
@ -362,8 +368,8 @@ library directory MUMPS built for %{mpi_family}%{?mpi_ver}.
%package examples
Summary: Simple test programs and examples for mumps
Group: System/Libraries
Requires: %{libname} = version
Group: Productivity/Scientific/Math
Requires: %{libname} = %version
%description examples
MUMPS implements a direct solver for large sparse linear systems, with a
@ -377,7 +383,7 @@ matlab and scilab extensions are provided in /usr/share/doc/packages/mumps.
%if %{with hpc}
%{hpc_master_package -l -L}
%{hpc_master_package -L devel}
%{hpc_master_package -L test}
%{hpc_master_package -L examples}
%{hpc_master_package doc}
%endif
@ -426,7 +432,6 @@ module load openblas scalapack
%define F_C mpif77
%define F_L mpif77
%define SCALAP -lscalapack -lblacs
%define MUMPS_MPI %{mpi_family}
%define MUMPS_LIBF77 %{!?with_hpc:-L%{my_libdir}} %{?mumps_f77_mpilibs}
%define INCPAR %{!?with_hpc:-I%{my_incdir}}
%define LIBPAR %{SCALAP} %{MUMPS_LIBF77}
@ -448,7 +453,6 @@ echo \
%{?F_C:FC=%F_C}
%{?F_L:FL=%F_L}
%{?SCALAP:SCALAP=%SCALAP}
%{?MUMPS_MPI:MUMPS_MPI=%MUMPS_MPI}
%{?INCPAR:INCPAR=%INCPAR}
%{?LIBPAR:LIBPAR=%LIBPAR}
%{?LIBBLAS:LIBBLAS=%LIBBLAS}
@ -538,13 +542,13 @@ proc ModulesHelp { } {
puts stderr " "
puts stderr "This module loads the mumps library built with the %{compiler_family} compiler"
puts stderr "toolchain and the %{mpi_family} MPI stack."
puts stderr "toolchain and the %{mpi_family}%{?mpi_ver} MPI stack."
puts stderr " "
puts stderr "\nVersion %{version}\n"
}
module-whatis "Name: %{pname} built with %{compiler_family} compiler%{?with_mpi: and %{mpi_family} MPI}"
module-whatis "Name: %{pname} built with %{compiler_family} compiler%{?with_mpi: and %{mpi_family}%{?mpi_ver} MPI}"
module-whatis "Version: %{version}"
module-whatis "Category: runtime library"
module-whatis "%{url}"
@ -621,7 +625,7 @@ rm -rf examples/*.o examples/*simpletest examples/c_example examples/multiple_ar
%{my_libdir}/*.a
%if %{with mpi} && %{without hpc}
%files %{so_ver}-static-compat
%files devel-static-compat
%{my_libdir}/*%{!?scotch:_seq}%{?scotch:_scotch}.a
%endif