File python3-FFC.spec of Package python3-FFC

#
# spec file for package python-FFC
#
# Copyright (c) 2020 SUSE LLC
#
# 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 https://bugs.opensuse.org/
#


%define modname FFC
%define pyname  ffc
Name:           python3-%{modname}
Version:        2019.1.0
Release:        0
Summary:        A compiler for multilinear forms by generating code
License:        LGPL-3.0-or-later
Group:          Development/Languages/Python
URL:            https://fenicsproject.org
Source0:        https://bitbucket.org/fenics-project/%{pyname}/downloads/%{pyname}-%{version}.tar.gz
BuildArch:      noarch
BuildRequires:  python3-setuptools
Requires:       python3-ufl = %{version}
Requires:       python3-dijitso = %{version}
Requires:       python3-FIAT = %{version}
Requires:       python3-six
Requires:       ufc-devel = %{version}

%description
FFC works as a compiler for multilinear forms by generating code (C++)
for the evaluation of a multilinear form given in mathematical notation.
This new approach to form evaluation makes it possible to combine generality
with efficiency; the form can be given in mathematical notation and the
generated code is as efficient as hand-optimized code.

%package -n ufc-devel
Summary:        Development and header files for UFC
Group:          Development/Libraries/C and C++

%description -n ufc-devel
This package contains the development files for UFC (Unified Form-assembly Code)

%prep
%setup -q -n %{pyname}-%{version}

%build
python3 setup.py build

%install
python3 setup.py install --root %{buildroot} --prefix=%{_prefix}

%files
%doc ChangeLog.rst README.rst
%license COPYING COPYING.LESSER
%{_bindir}/%{pyname}
%{_bindir}/%{pyname}-3
%exclude %{python3_sitelib}/%{pyname}/backends/ufc/*.h
%{python3_sitelib}/%{pyname}
%{python3_sitelib}/*-%{version}-py%{py3_ver}.egg-info
%{_mandir}/man1/*

%files -n ufc-devel
%{python3_sitelib}/%{pyname}/backends/ufc/*.h

%changelog
openSUSE Build Service is sponsored by