Blob Blame Raw
%global pkgname mongoengine
%global sum A Python Document-Object Mapper for working with MongoDB
%global desc MongoEngine is a Document-Object Mapper (think ORM, \
but for document databases) for working with MongoDB \
from Python. It uses a simple declarative API, similar \
to the Django ORM.


Name: python-%{pkgname}
Version: 0.15.3
Release: 3%{?dist}
BuildArch: noarch

License: MIT
Summary: %{sum}
URL:     http://mongoengine.org/
Source0: https://github.com/MongoEngine/mongoengine/archive/v%{version}/%{pkgname}-%{version}.tar.gz

# pymongo and pymongo-gridfs is needed for the docs
BuildRequires: python3-pymongo
BuildRequires: python3-pymongo-gridfs
BuildRequires: python3-sphinx
BuildRequires: python3-devel


%description
%{desc}


%package -n python3-%{pkgname}
Summary: %{sum}
Requires: python3-blinker
Requires: python3-pillow
Requires: python3-pymongo
Requires: python3-pymongo-gridfs
Requires: python3-six
%{?python_provide:%python_provide python3-%{pkgname}}


%description -n python3-%{pkgname}
%{desc}


%package doc
Summary: Documentation for %{name}
BuildArch: noarch


%description doc
Documentation for %{name}.


%prep
%setup -q -n %{pkgname}-%{version}
find . -name '*.py' | xargs sed -i '1s|^#!.*|#!%{__python3}|'


%build
%py3_build
PYTHONPATH=$(pwd) make -C docs SPHINXBUILD=sphinx-build-3 html
rm -f docs/_build/html/.buildinfo
# Don't ship fonts
rm -rf docs/_build/html/_static/font


%install
%py3_install


%files -n python3-%{pkgname}
%license LICENSE
%doc README.rst
%{python3_sitelib}/%{pkgname}
%{python3_sitelib}/%{pkgname}-*.egg-info


%files doc
%license LICENSE
%doc docs/_build/html


%changelog
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.15.3-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild

* Wed Jan 09 2019 Miro Hrončok <mhroncok@redhat.com> - 0.15.3-2
- Subpackage python2-mongoengine has been removed
  See https://fedoraproject.org/wiki/Changes/Mass_Python_2_Package_Removal

* Sun Jul 29 2018 Randy Barlow <bowlofeggs@fedoraproject.org> - 0.15.3-1
- Update to 0.15.3 (#1597681).
- https://github.com/MongoEngine/mongoengine/blob/v0.15.3/docs/changelog.rst

* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.15.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild

* Tue Jun 19 2018 Miro Hrončok <mhroncok@redhat.com> - 0.15.1-2
- Rebuilt for Python 3.7

* Sat Apr 28 2018 Randy Barlow <bowlofeggs@fedoraproject.org> - 0.15.1-1
- Update to 0.15.1 (#1504393).
- https://github.com/MongoEngine/mongoengine/blob/v0.15.1/docs/changelog.rst

* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.14.0-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild

* Thu Jan 25 2018 Iryna Shcherbina <ishcherb@redhat.com> - 0.14.0-3
- Update Python 2 dependency declarations to new packaging standards
  (See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3)

* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.14.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild

* Sat Jun 03 2017 Randy Barlow <bowlofeggs@fedoraproject.org> - 0.14.0-1
- Update to 0.14.0 (#1442650).

* Wed Apr 12 2017 Randy Barlow <bowlofeggs@fedoraproject.org> - 0.12.0-1
- Update to 0.12.0 (#1440451).
- Use a GitHub URL that gives us a name-version.tar.gz.
- Update the URL to the upstream website.

* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.11.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild