[openstack-nova] Add a dep to python-six and fix version reporting
Nikola Dipanov
ndipanov at fedoraproject.org
Mon Jun 10 12:51:00 UTC 2013
commit edc2b31111feffbf74656da9a82f6971ba0fbc81
Author: Nikola Dipanov <ndipanov at redhat.com>
Date: Mon Jun 10 13:05:57 2013 +0200
Add a dep to python-six and fix version reporting
0002-Remove-a-run-time-dep-on-python-pbr.patch | 101 --------------------
...emove-a-runtime-dep-on-python-pbr-package.patch | 63 ++++++++++++
openstack-nova.spec | 12 ++-
3 files changed, 72 insertions(+), 104 deletions(-)
---
diff --git a/0002-Remove-a-runtime-dep-on-python-pbr-package.patch b/0002-Remove-a-runtime-dep-on-python-pbr-package.patch
new file mode 100644
index 0000000..348aed4
--- /dev/null
+++ b/0002-Remove-a-runtime-dep-on-python-pbr-package.patch
@@ -0,0 +1,63 @@
+From 539ba73977ef8afcde317b611b798a21406dac27 Mon Sep 17 00:00:00 2001
+From: Nikola Dipanov <ndipanov at redhat.com>
+Date: Mon, 10 Jun 2013 12:46:42 +0200
+Subject: [PATCH] Remove a runtime dep on python-pbr package
+
+Also patch it out when building docs to have consistent versioning
+---
+ doc/source/conf.py | 8 ++++++--
+ nova/version.py | 9 +++------
+ 2 files changed, 9 insertions(+), 8 deletions(-)
+
+diff --git a/doc/source/conf.py b/doc/source/conf.py
+index 85e2629..699728f 100644
+--- a/doc/source/conf.py
++++ b/doc/source/conf.py
+@@ -63,11 +63,15 @@ copyright = u'2010-present, OpenStack Foundation'
+ # |version| and |release|, also used in various other places throughout the
+ # built documents.
+ #
+-from nova.version import version_info
++from nova.version import version_string
++import pbr.version
++
++version_info = pbr.version.VersionInfo('nova')
++
+ # The full version, including alpha/beta/rc tags.
+ release = version_info.release_string()
+ # The short X.Y version.
+-version = version_info.version_string()
++version = version_string
+
+ # The language for content autogenerated by Sphinx. Refer to documentation
+ # for a list of supported languages.
+diff --git a/nova/version.py b/nova/version.py
+index f954ef3..7c38a77 100644
+--- a/nova/version.py
++++ b/nova/version.py
+@@ -14,15 +14,12 @@
+ # License for the specific language governing permissions and limitations
+ # under the License.
+
+-import pbr.version
+-
+ NOVA_VENDOR = "OpenStack Foundation"
+ NOVA_PRODUCT = "OpenStack Nova"
+ NOVA_PACKAGE = None # OS distro package version suffix
+
+ loaded = False
+-version_info = pbr.version.VersionInfo('nova')
+-version_string = version_info.version_string
++version_string = "REDHATNOVAVERSION"
+
+
+ def _load_config():
+@@ -85,6 +82,6 @@ def package_string():
+
+ def version_string_with_package():
+ if package_string() is None:
+- return version_info.version_string()
++ return version_string
+ else:
+- return "%s-%s" % (version_info.version_string(), package_string())
++ return "%s-%s" % (version_string, package_string())
diff --git a/openstack-nova.spec b/openstack-nova.spec
index 753a19e..6c2970f 100644
--- a/openstack-nova.spec
+++ b/openstack-nova.spec
@@ -2,7 +2,7 @@
Name: openstack-nova
Version: 2013.2
-Release: 0.1.h1%{?dist}
+Release: 0.2.h1%{?dist}
Summary: OpenStack Compute (nova)
Group: Applications/System
@@ -36,7 +36,7 @@ Source24: nova-sudoers
# patches_base=2013.2.b1
#
Patch0001: 0001-Ensure-we-don-t-access-the-net-when-building-docs.patch
-Patch0002: 0002-Remove-a-run-time-dep-on-python-pbr.patch
+Patch0002: 0002-Remove-a-runtime-dep-on-python-pbr-package.patch
BuildArch: noarch
BuildRequires: intltool
@@ -325,6 +325,7 @@ Requires: python-quantumclient >= 1:2
Requires: python-novaclient
Requires: python-oslo-config
Requires: python-pyasn1
+Requires: python-six
%description -n python-nova
OpenStack Compute (codename Nova) is open source software designed to
@@ -369,6 +370,7 @@ find . \( -name .gitignore -o -name .placeholder \) -delete
find nova -name \*.py -exec sed -i '/\/usr\/bin\/env python/{d;q}' {} +
sed -i '/setuptools_git/d' setup.py
+sed -i s/REDHATNOVAVERSION/%{version}/ nova/version.py
%build
%{__python} setup.py build
@@ -793,7 +795,11 @@ fi
%endif
%changelog
-* Fri Jun 7 2013 Nikola Đipanov <ndipanov at redhat.com> - 2013.2-0.1.h1
+* Mon Jun 10 2013 Nikola Đipanov <ndipanov at redhat.com> - 2013.2-0.2.h1
+- Add a runtime dep on python-six
+- Fix verision reporting
+
+* Fri Jun 07 2013 Nikola Đipanov <ndipanov at redhat.com> - 2013.2-0.1.h1
- Update to Havana milestone 1
- Add a build-time dep on python-d2to1
- Add a build-time dep on python-pbr
More information about the scm-commits
mailing list