From 388cd90ac2525e6c0fac78150139f6e10eaaa6ed Mon Sep 17 00:00:00 2001 From: Matthias Runge Date: Aug 27 2015 10:05:12 +0000 Subject: update to 1.0.1 and python3 subpackage --- diff --git a/.gitignore b/.gitignore index 53e5540..72d0a6a 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ /django-appconf-0.5.tar.gz /django-appconf-0.6.tar.gz +/django-appconf-1.0.1.tar.gz diff --git a/python-django-appconf.spec b/python-django-appconf.spec index 07e3c27..8258e17 100644 --- a/python-django-appconf.spec +++ b/python-django-appconf.spec @@ -1,59 +1,132 @@ +%{!?__python2:%global __python2 %{__python}} +%{!?python2_sitelib: %global python2_sitelib %{python_sitelib}} +%{!?python2_sitearch: %global python2_sitearch %{python_sitearch}} +%{!?python2_version: %global python2_version %{python_version}} + %global pypi_name django-appconf +%if 0%{?fedora} > 12 +%global with_python3 1 +%else +%global with_python3 0 +%endif + Name: python-%{pypi_name} -Version: 0.6 -Release: 4%{?dist} +Version: 1.0.1 +Release: 1%{?dist} Summary: A helper class for handling configuration defaults of packaged apps gracefully License: BSD -URL: http://pypi.python.org/pypi/django-appconf/0.5 +URL: http://pypi.python.org/pypi/django-appconf/ Source0: http://pypi.python.org/packages/source/d/%{pypi_name}/%{pypi_name}-%{version}.tar.gz BuildArch: noarch - + BuildRequires: python2-devel BuildRequires: python-sphinx -#BuildRequires: python-django-discover-runner +BuildRequires: python-setuptools -%if 0%{?rhel}<7 || 0%{?fedora} < 18 -Requires: Django -%else -Requires: python-django -%endif +BuildRequires: python-django-discover-runner +BuildRequires: python-flake8 +BuildRequires: python-coverage +BuildRequires: python-django %description A helper class for handling configuration defaults of packaged Django apps gracefully. +%if 0%{?with_python3} +%package -n python3-%{pypi_name} +Summary: A helper class for handling configuration defaults of packaged apps gracefully + +BuildRequires: python3-devel +BuildRequires: python-sphinx +BuildRequires: python3-setuptools + +Requires: python-django + +%description -n python3-%{pypi_name} +A helper class for handling configuration +defaults of packaged Django +apps gracefully. + +%endif %prep -%setup -q -n %{pypi_name}-%{version} -# Remove bundled egg-info -rm -rf %{pypi_name}.egg-info +%setup -qc +mv %{pypi_name}-%{version} python2 + +pushd python2 + +# copy license etc to top level dir +cp -a README.rst .. +cp -a LICENSE .. -# generate html docs +# generate html docs sphinx-build docs html # remove the sphinx-build leftovers rm -rf html/.{doctrees,buildinfo} +# move html up to get picked up for docs +mv html .. + +popd + +%if 0%{?with_python3} +cp -a python2 python3 +%endif %build -%{__python} setup.py build +pushd python2 +%{__python2} setup.py build +popd + +%if 0%{?with_python3} +pushd python3 +%{__python3} setup.py build +popd +%endif %install -%{__python} setup.py install --skip-build --root %{buildroot} +pushd python2 +%{__python2} setup.py install --skip-build --root %{buildroot} +popd + +%if 0%{?with_python3} +pushd python3 +%{__python3} setup.py install --skip-build --root %{buildroot} +popd +%endif # checks fail in mock -#%check -#%{__python} setup.py test +%check +pushd python2 +%{__python} setup.py test +export PYTHONPATH=.:$PYTHONPATH +export DJANGO_SETTINGS_MODULE=tests.test_settings +coverage run %{_bindir}/django-admin test -v2 test +popd %files -%doc html README.rst LICENSE -%{python_sitelib}/appconf -%{python_sitelib}/django_appconf-%{version}-py?.?.egg-info +%doc html README.rst +%license LICENSE +%{python2_sitelib}/appconf +%{python2_sitelib}/django_appconf-%{version}-py%{python2_version}.egg-info + +%if 0%{?with_python3} +%files -n python3-%{pypi_name} +%doc html README.rst +%license LICENSE +%{python3_sitelib}/appconf +%{python3_sitelib}/django_appconf-%{version}-py%{python3_version}.egg-info +%endif %changelog +* Thu Aug 27 2015 Matthias Runge - 1.0.1-1 +- update to 1.0.1 +- python3 subpackage + * Thu Jun 18 2015 Fedora Release Engineering - 0.6-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild diff --git a/sources b/sources index c42f8dd..a11556b 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -40494042c3c8bd1e054c884e5ed4bb6c django-appconf-0.6.tar.gz +29c87a00f0d098b90f3ac6113ae6e52d django-appconf-1.0.1.tar.gz