[kobo] Bump version to 0.4.0.
dmach
dmach at fedoraproject.org
Thu Jul 25 07:10:32 UTC 2013
commit 3568cbfbabaaec035b0cba22fb14938cc227b30c
Author: Daniel Mach <dmach at redhat.com>
Date: Thu Jul 25 09:10:11 2013 +0200
Bump version to 0.4.0.
.gitignore | 1 +
kobo.spec | 90 ++++++++++++++++++++++++++++++++++++++++--------------------
sources | 2 +-
3 files changed, 62 insertions(+), 31 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 28e833a..ff94b5e 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,3 +2,4 @@
/kobo-0.3.6.tar.bz2
/kobo-0.3.7.tar.bz2
/kobo-0.3.8.tar.bz2
+/kobo-0.4.0.tar.bz2
diff --git a/kobo.spec b/kobo.spec
index 76e0c5d..09ecd8c 100644
--- a/kobo.spec
+++ b/kobo.spec
@@ -1,23 +1,24 @@
-%define py_version %(%{__python} -c "import sys; v=sys.version_info[:2]; print '%%d.%%d'%%v" 2>/dev/null || echo PYTHON-NOT-FOUND)
-%define py_prefix %(%{__python} -c "import sys; print sys.prefix" 2>/dev/null || echo PYTHON-NOT-FOUND)
-%define py_libdir %{py_prefix}/lib/python%{py_version}
-%define py_incdir %{py_prefix}/include/python%{py_version}
-%define py_sitedir %{py_libdir}/site-packages
%define debug_package %{nil}
-%define version 0.3.8
-%define release 1
-# set git to %{nil} (release) or to YYYYMMDD.123456 (git build)
-%define git %{nil}
+%define python_version %(%{__python} -c "import sys; print '%%d.%%d' %% sys.version_info[:2]")
+%if 0%{?rhel} && 0%{?rhel} <= 5
+%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")}
+%{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")}
+%endif
+
+%define with_django 1
+%define with_hub 1
-%if "%{?git}" != ""
-%define release_prefix 0.
-%define release_suffix .git.%{git}
+# Turn off Django support on RHEL 5 - Django 1.5 is not supported on Python 2.4
+%if 0%{?rhel} == 5
+%define with_django 0
+%define with_hub 0
%endif
+
Name: kobo
-Version: %{version}
-Release: %{?release_prefix}%{release}%{?release_suffix}%{?dist}
+Version: 0.4.0
+Release: 1%{?dist}
License: LGPLv2
Summary: Python modules for tools development
Group: Development/Libraries
@@ -29,7 +30,7 @@ BuildArch: noarch
BuildRequires: python-devel >= 2.4
# require additional packages for python 2.4
-%if "%{py_version}" == "2.4"
+%if "%{python_version}" == "2.4"
Requires: python-hashlib
Requires: python-ssl
%endif
@@ -39,13 +40,16 @@ Requires: python-ssl
Kobo is a set of python modules designed for rapid tools development.
+%if 0%{?with_django}
%package django
Summary: Django components
Group: Development/Libraries
Requires: kobo = %{version}-%{release}
+Requires: Django >= 1.5
%description django
Django components.
+%endif
%package client
@@ -67,6 +71,7 @@ Requires: kobo = %{version}-%{release}
Worker daemon processing tasks submitted to the hub.
+%if 0%{?with_hub}
%package hub
Summary: Xml-rpc and web interface to a task database
Group: Development/Libraries
@@ -76,6 +81,7 @@ Requires: gzip
%description hub
Hub is a xml-rpc and web interface to a task database.
+%endif
%package rpmlib
@@ -103,19 +109,22 @@ incl. CLI, hub client, worker and hub.
%prep
%setup -q -n %{name}-%{version}%{?release_suffix}
+
%build
-echo OK
+%{__python} setup.py build
%install
rm -rf ${RPM_BUILD_ROOT}
-python setup.py install --root=${RPM_BUILD_ROOT}
+%{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
+
+%if ! 0%{?with_django}
+rm -rf $RPM_BUILD_ROOT/%{python_sitelib}/kobo/django
+%endif
-# delete the egg-info file
-egg_info=$RPM_BUILD_ROOT/%{py_sitedir}/%{name}-*.egg-info
-if [ -f $egg_info ]; then
- rm $egg_info
-fi
+%if ! 0%{?with_hub}
+rm -rf $RPM_BUILD_ROOT/%{python_sitelib}/kobo/hub
+%endif
%clean
@@ -124,44 +133,65 @@ rm -rf $RPM_BUILD_ROOT
%files
%defattr(644,root,root,755)
-%{py_sitedir}/kobo/*.py*
-%exclude %{py_sitedir}/kobo/rpmlib.py*
+%{python_sitelib}/kobo/*.py*
+%exclude %{python_sitelib}/kobo/rpmlib.py*
%doc AUTHORS
%doc COPYING
%doc LICENSE
+%if "%{python_version}" != "2.4"
+%{python_sitelib}/%{name}-%{version}-py?.?.egg-info
+%endif
+%if 0%{?with_django}
%files django
%defattr(644,root,root,755)
-%{py_sitedir}/kobo/django
+%{python_sitelib}/kobo/django
+%endif
%files client
%defattr(644,root,root,755)
-%{py_sitedir}/kobo/client
+%{python_sitelib}/kobo/client
%files worker
%defattr(644,root,root,755)
-%{py_sitedir}/kobo/worker
+%{python_sitelib}/kobo/worker
+%if 0%{?with_hub}
%files hub
%defattr(644,root,root,755)
-%{py_sitedir}/kobo/hub
+%{python_sitelib}/kobo/hub
+%endif
%files rpmlib
%defattr(644,root,root,755)
-%{py_sitedir}/kobo/rpmlib.py*
+%{python_sitelib}/kobo/rpmlib.py*
+
%files admin
%defattr(644,root,root,755)
-%{py_sitedir}/kobo/admin
+%{python_sitelib}/kobo/admin
%attr(755,root,root) /usr/bin/kobo-admin
%changelog
+* Thu Jul 25 2013 Daniel Mach <dmach at redhat.com> - 0.4.0-1
+- Drop django and hub subpackages on rhel <= 5
+- Set filename to be real name of a downloaded file. (Tomas Tomecek)
+- Fix logwatcher to scroll to latest logs. (Tomas Tomecek)
+- Remove obsolete function kobo.django.views.generic._object_list(). (Tomas Kopecek)
+- Updated README for 0.4.0 release (Tomas Kopecek)
+- Revamp setup.py and related files. (Daniel Mach)
+- LongnameUser table has auth_user db table name for easier upgrade. (Tomas Kopecek)
+- Add checksum_type to SimpleRpmWrapper. (Tomas Kopecek)
+- Add kobo.threads.run_in_threads() helper. (Tomas Kopecek)
+- Django 1.5 rebase. (Tomas Kopecek)
+- Remove unnecessary slots from pkgset.FileCache. (Daniel Mach)
+
* Mon Feb 11 2013 Daniel Mach <dmach at redhat.com> - 0.3.8-1
- Don't catch and mask any exceptions in cli.CommandOptionParser.run(). (Daniel Mach)
- Set an empty keyring in rpmlib.get_rpm_header(). (Daniel Mach)
diff --git a/sources b/sources
index 7bc33c5..e5ac5e7 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-76f7b994dd3af1ac74269e34294c354f kobo-0.3.8.tar.bz2
+b9774da41fcd3b60b0e729234ec7f6c2 kobo-0.4.0.tar.bz2
More information about the scm-commits
mailing list