Blob Blame History Raw
%global srcname camel
%global sum Python serialization for adults

Name:		python-%{srcname}
Version:	0.1.2
Release:	1%{?dist}
Summary:	%{sum}

License:	ISC
URL:		http://github.com/eevee/camel
Source0:	https://github.com/eevee/%{srcname}/archive/v%{version}.tar.gz

BuildRequires:	python2-devel
BuildRequires:	python3-devel
BuildRequires:	git
# %check dependencies
BuildRequires:	PyYAML
BuildRequires:	python3-PyYAML
BuildRequires:	python2-pytest
BuildRequires:	python3-pytest

BuildArch:  noarch

%description
Camel is a library that lets you describe how to serialize
your objects in YAML - and refuses to serialize them if
you don't.

%package -n python2-%{srcname}
Summary:	%{sum}
%{?python_provide:%python_provide python2-%{srcname}}

%description -n python2-%{srcname}
Camel is a library that lets you describe how to serialize
your objects in YAML - and refuses to serialize them if
you don't.

%package -n python3-%{srcname}
Summary:	%{sum}
%{?python_provide:%python_provide python3-%{srcname}}

%description -n python3-%{srcname}
Camel is a library that lest you describe how to serialize
your objects in YAML - and refuses to serialize them if
you don't.

%prep
%autosetup -n %{srcname}-%{version}

%build
%py2_build
%py3_build


%install
%py2_install
%py3_install

%check
pushd %{buildroot}%{python2_sitelib}/%{srcname}/tests
%{__python2} -m pytest
popd
pushd %{buildroot}%{python3_sitelib}/%{srcname}/tests
%{__python3} -m pytest
popd

%files -n python2-%{srcname}
%doc README.txt
%license LICENSE
%{python2_sitelib}/%{srcname}
%{python2_sitelib}/%{srcname}-%{version}-py%{python2_version}.egg-info

%files -n python3-%{srcname}
%doc README.txt
%license LICENSE
%{python3_sitelib}/%{srcname}
%{python3_sitelib}/%{srcname}-%{version}-py%{python3_version}.egg-info

%changelog
* Mon May 29 2017 Greg Hellings <greg.hellings@gmail.com> - 0.1.2-1
- Upstream version 0.1.2

* Mon May 01 2017 Greg Hellings <greg.hellings@gmail.com> - 0.1.1-2
- Added license tag and file

* Fri Apr 21 2017 Greg Hellings <greg.hellings@gmail.com> - 0.1.1-1
- Upstream release 0.1.1
- Allowed removal of patches and extra files

* Wed Apr 19 2017 Greg Hellings <greg.hellings@gmail.com> - 0.1-3
- Fixed check to run the actual tests
- Added README.txt to docs

* Fri Apr 14 2017 Greg Hellings <greg.hellings@gmail.com> - 0.1-2
- Added link to patch source
- Corrected license claim

* Mon Apr 03 2017 Greg Hellings <greg.hellings@gmail.com> - 0.1-1
- Upstream version 0.1