Commit 8285d13b authored by Lorenz Huedepohl's avatar Lorenz Huedepohl
Browse files

Adapt spec file for restricted obs spec file parser

parent b483df9b
...@@ -19,6 +19,18 @@ ...@@ -19,6 +19,18 @@
# Set to 0 to disable # Set to 0 to disable
%define with_openmp 1 %define with_openmp 1
# Logic to figure out if we are on SLES-11-SP4, which need special
# treatment (custom compiler package name, old RPM macros)
%if 0%{suse_version} > 0
%if 0%{suse_version} <= 1110
%define sle_11_sp4 1
%else
%define sle_11_sp4 0
%endif
%else
%define sle_11_sp4 0
%endif
Name: elpa Name: elpa
Version: 2016.05.002 Version: 2016.05.002
Release: 2 Release: 2
...@@ -29,12 +41,12 @@ Url: https://elpa.rzg.mpg.de/ ...@@ -29,12 +41,12 @@ Url: https://elpa.rzg.mpg.de/
Source0: https://elpa.mpcdf.mpg.de/html/Releases/%{version}/%{name}-%{version}.tar.gz Source0: https://elpa.mpcdf.mpg.de/html/Releases/%{version}/%{name}-%{version}.tar.gz
Requires: openmpi Requires: openmpi
# For SLE_11_SP4: # For SLE_11_SP4:
%if %{?suse_version:%{suse_version}}%{!?suse_version:1200} <= 1110 %if %{sle_11_sp4} == 1
BuildRequires: gcc48-c++ BuildRequires: gcc48-c++
BuildRequires: gcc48-fortran BuildRequires: gcc48-fortran
%else %else
BuildRequires: gcc-c++ >= 4.8.0 BuildRequires: gcc-c++ >= 4.8
BuildRequires: gcc-fortran >= 4.8.0 BuildRequires: gcc-fortran >= 4.8
%endif %endif
BuildRequires: strace BuildRequires: strace
BuildRequires: openmpi-devel BuildRequires: openmpi-devel
...@@ -197,7 +209,7 @@ if [ ! -e configure ] ; then ...@@ -197,7 +209,7 @@ if [ ! -e configure ] ; then
fi fi
# Set-up compilers for SLE_11_SP4 # Set-up compilers for SLE_11_SP4
%if %{?suse_version:%{suse_version}}%{!?suse_version:1200} <= 1110 %if %{sle_11_sp4} == 1
mkdir compilers mkdir compilers
pushd compilers pushd compilers
ln -s /usr/bin/gfortran-4.8 gfortran ln -s /usr/bin/gfortran-4.8 gfortran
...@@ -213,7 +225,7 @@ pushd build ...@@ -213,7 +225,7 @@ pushd build
# ancient SLE_11_SP4 cannot deal with configure in sub-directory # ancient SLE_11_SP4 cannot deal with configure in sub-directory
# via _configure macro # via _configure macro
%if %{?suse_version:%{suse_version}}%{!?suse_version:1200} <= 1110 %if %{sle_11_sp4} == 1
ln -s ../configure . ln -s ../configure .
%endif %endif
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment