Blame python-xnat.spec

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