File python-gsw.spec of Package python-gsw
#
# spec file for package python-gsw
#
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
# Note: this package is python3-only. There is a python2-compatible
# version in the python2-gsw package.
# Tests are not included in the source tarball
%define skip_python2 1
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name: python-gsw
Version: 3.2.0
Release: 0
Summary: Gibbs Seawater Oceanographic Package of TEOS-10
# Note: Python code is MIT licensed
# C-code IS BSD-3-Clause licensed (see src/c_gsw/LICENSE)
# MATLAB function names and documentation are BSD-3-Clause licensed (see http://teos-10.org/pubs/gsw/html/gsw_licence.html)
License: MIT AND BSD-3-Clause
Group: Development/Languages/Python
Url: https://github.com/TEOS-10/GSW-python
Source: https://files.pythonhosted.org/packages/source/g/gsw/gsw-%{version}.tar.gz
Source1: http://teos-10.org/pubs/gsw/html/gsw_licence.html
BuildRequires: %{python_module devel >= 3.5}
BuildRequires: %{python_module numpy-devel}
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
# SECTION tests
BuildRequires: %{python_module pytest}
# /SECTION
Requires: python-numpy
%{python_subpackages}
%description
Python implementation of the Thermodynamic Equation of
Seawater 2010 (TEOS-10).
%prep
%setup -q -n gsw-%{version}
cp %{SOURCE1} .
%build
export CFLAGS="%{optflags}"
%{python_build}
%install
%{python_install}
%{python_expand %fdupes %{buildroot}%{$python_sitearch}}
%files %{python_files}
%doc README.rst
%doc LICENSE src/c_gsw/LICENSE gsw_licence.html
%{python_sitearch}/*
%changelog