opm-simulators/redhat/opm-simulators.spec

94 lines
3.3 KiB
RPMSpec
Raw Normal View History

2013-10-30 07:22:04 -05:00
#
# spec file for package opm-autodiff
#
2017-10-25 02:46:00 -05:00
%define tag rc1
2013-10-30 07:22:04 -05:00
Name: opm-simulators
2017-10-25 02:46:00 -05:00
Version: 2017.10
2013-10-30 07:22:04 -05:00
Release: 0
Summary: Open Porous Media - core library
License: GPL-3.0
Group: Development/Libraries/C and C++
Url: http://www.opm-project.org/
Source0: https://github.com/OPM/%{name}/archive/release/%{version}/%{tag}.tar.gz#/%{name}-%{version}.tar.gz
BuildRequires: blas-devel lapack-devel dune-common-devel opm-output-devel
2017-10-25 02:46:00 -05:00
BuildRequires: git suitesparse-devel doxygen bc devtoolset-6-toolchain
BuildRequires: opm-parser-devel opm-core-devel opm-grid-devel
2017-10-25 02:46:00 -05:00
BuildRequires: tinyxml-devel dune-istl-devel eigen3-devel ecl-devel ewoms-devel
%{?el6:BuildRequires: cmake3 boost148-devel}
%{!?el6:BuildRequires: cmake boost-devel}
2013-10-30 07:22:04 -05:00
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Requires: libopm-simulators1 = %{version}
2013-10-30 07:22:04 -05:00
%description
The Open Porous Media (OPM) initiative provides a set of open-source tools centered around the simulation of flow and transport of fluids in porous media. The goal of the initiative is to establish a sustainable environment for the development of an efficient and well-maintained software suite.
%package -n libopm-simulators1
2013-10-30 07:22:04 -05:00
Summary: Open Porous Media - automatic differentiation library
Group: System/Libraries
%description -n libopm-simulators1
2013-10-30 07:22:04 -05:00
The Open Porous Media (OPM) initiative provides a set of open-source tools centered around the simulation of flow and transport of fluids in porous media. The goal of the initiative is to establish a sustainable environment for the development of an efficient and well-maintained software suite.
%package devel
Summary: Development and header files for opm-simulators
2013-10-30 07:22:04 -05:00
Group: Development/Libraries/C and C++
Requires: libopm-simulators1 = %{version}
2013-10-30 07:22:04 -05:00
%description devel
This package contains the development and header files for opm-simulators
2013-10-30 07:22:04 -05:00
%package doc
Summary: Documentation files for opm-simulators
2013-10-30 07:22:04 -05:00
Group: Documentation
BuildArch: noarch
%description doc
This package contains the documentation files for opm-simulators
2013-10-30 07:22:04 -05:00
%package bin
Summary: Applications in opm-simulators
2013-10-30 07:22:04 -05:00
Group: Scientific
Requires: libopm-simulators1 = %{version}
2013-10-30 07:22:04 -05:00
%description bin
This package contains the applications for opm-simulators
2013-10-30 07:22:04 -05:00
%prep
%setup -q -n %{name}-release-%{version}-%{tag}
%build
2017-10-25 02:46:00 -05:00
scl enable devtoolset-6 bash
%{?el6:cmake3} %{?!el6:cmake} -DBUILD_SHARED_LIBS=1 -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=%{_prefix} -DCMAKE_INSTALL_DOCDIR=share/doc/%{name}-%{version} -DUSE_RUNPATH=OFF -DWITH_NATIVE=OFF -DCMAKE_CXX_COMPILER=/opt/rh/devtoolset-6/root/usr/bin/g++ -DCMAKE_C_COMPILER=/opt/rh/devtoolset-6/root/usr/bin/gcc %{?el6:-DBOOST_LIBRARYDIR=%{_libdir}/boost148 -DBOOST_INCLUDEDIR=%{_includedir}/boost148}
2013-10-30 07:22:04 -05:00
make
%install
make install DESTDIR=${RPM_BUILD_ROOT}
make install-html DESTDIR=${RPM_BUILD_ROOT}
%clean
rm -rf %{buildroot}
%post -n libopm-simulators1 -p /sbin/ldconfig
2013-10-30 07:22:04 -05:00
%postun -n libopm-simulators1 -p /sbin/ldconfig
2013-10-30 07:22:04 -05:00
%files doc
%{_docdir}/*
%files -n libopm-simulators1
2013-10-30 07:22:04 -05:00
%defattr(-,root,root,-)
%{_libdir}/*.so.*
%files devel
%defattr(-,root,root,-)
%{_libdir}/*.so
%{_libdir}/dunecontrol/*
%{_libdir}/pkgconfig/*
%{_includedir}/*
%{_datadir}/cmake/*
%files bin
%{_bindir}/*