Blame python-xnat.spec

4c398f
%if 0%{?fedora} >= 30
4c398f
# disabled by default
4c398f
%bcond_with py2
4c398f
%else
4c398f
%bcond_without py2
4c398f
%endif
4c398f
1bf792
%bcond_with tests
4c398f
d8bae9
%global pypi_name xnat
4c398f
%global desc %{expand: \
4c398f
A new XNAT client that exposes XNAT objects/functions as python objects/functions.
4c398f
The aim is to abstract as much of the REST API away as possible and make xnatpy feel
4c398f
like native Python code. This reduces the need for the user to know the details
4c398f
of the REST API. Low level functionality can still be accessed via the connection object
4c398f
which has get, head, put, post, delete methods for more directly calling the REST API.}
d8bae9
d8bae9
Name:           python-%{pypi_name}
d8bae9
Version:        0.3.11
1c5fc2
Release:        3%{?dist}
d8bae9
Summary:        A new XNAT client that exposes XNAT objects/functions as python objects/functions.
d8bae9
License:        ASL 2.0
d8bae9
URL:            http://pypi.python.org/pypi/%{pypi_name}/%{version}
d8bae9
Source0:        https://pypi.python.org/packages/source/x/%{pypi_name}/%{pypi_name}-%{version}.tar.gz
d8bae9
BuildArch:      noarch
d8bae9
d8bae9
%description
4c398f
%{desc}
4c398f
4c398f
%if %{with py2}
4c398f
%package -n python2-%{pypi_name}
4c398f
Summary:        %{summary}
4c398f
4c398f
BuildRequires: python2-devel
4c398f
BuildRequires: python2-setuptools
4c398f
BuildRequires: python2-isodate
4c398f
BuildRequires: python2-requests
4c398f
#BuildRequires: python2-progressbar2
4c398f
BuildRequires: python2-sphinx_rtd_theme
4c398f
BuildRequires: python2-six
4c398f
4c398f
%{?python_provide:%python_provide python2-%{pypi_name}}
4c398f
4c398f
%description -n python2-%{pypi_name}
4c398f
%{desc}
4c398f
%endif
d8bae9
d8bae9
%package -n python3-%{pypi_name}
4c398f
Summary:        %{summary}
4c398f
4c398f
BuildRequires: python3-devel
4c398f
BuildRequires: python3-setuptools
4c398f
BuildRequires: python3-isodate
4c398f
BuildRequires: python3-requests
4c398f
BuildRequires: python3-utils
4c398f
#BuildRequires: python3-progressbar2
4c398f
BuildRequires: python3-sphinx_rtd_theme
4c398f
BuildRequires: python3-six
d8bae9
d8bae9
%{?python_provide:%python_provide python3-%{pypi_name}}
d8bae9
d8bae9
%description -n python3-%{pypi_name}
4c398f
%{desc}
d8bae9
d8bae9
%prep
6cfc2e
%autosetup -n %{pypi_name}-%{version}
6cfc2e
rm -rf %{pypi_name}.egg-info
d8bae9
d8bae9
%build
d8bae9
%py3_build
4c398f
%if %{with py2}
4c398f
%py2_build
4c398f
%endif
d8bae9
d8bae9
%install
4c398f
%if %{with py2}
4c398f
%py2_install
4c398f
%endif
d8bae9
%py3_install
4c398f
4c398f
%check
4c398f
%if %{with tests}
4c398f
%if %{with py2}
4c398f
%{__python2} setup.py test
4c398f
%endif
4c398f
%{__python3} setup.py test
4c398f
%endif
d8bae9
 
4c398f
%if %{with py2}
4c398f
%files -n python2-%{pypi_name}
4c398f
%license LICENSE
4c398f
%doc README
4c398f
%{_bindir}/xnat_cp_project
4c398f
%{python2_sitelib}/%{pypi_name}-%{version}-py2.?.egg-info
4c398f
%{python2_sitelib}/%{pypi_name}
4c398f
%endif
4c398f
d8bae9
%files -n python3-%{pypi_name}
d8bae9
%license LICENSE
d8bae9
%doc README
d8bae9
%{_bindir}/xnat_cp_project
d8bae9
%{python3_sitelib}/xnat/
d8bae9
%{python3_sitelib}/xnat*.egg-info
d8bae9
d8bae9
%changelog
1c5fc2
* Thu Nov 29 2018 Luis Bazan <lbazan@fedoraproject.org> - 0.3.11-3
1c5fc2
- Use template of neuro-sig
1c5fc2
1c5fc2
* Tue Nov 20 2018 Luis Bazan <lbazan@fedoraproject.org> - 0.3.11-2
1c5fc2
- Add remove bundled egg info
6cfc2e
d8bae9
* Mon Nov 19 2018 Luis Bazan <lbazan@fedoraproject.org> - 0.3.11-1
d8bae9
- New upstream