[openstack-neutron/el6-icehouse] remove runtime dependency on python-pbr

Pádraig Brady pbrady at fedoraproject.org
Fri Apr 4 01:23:31 UTC 2014


commit 4c44f9156381243fdb41f83d0f9db22c5a75749d
Author: Pádraig Brady <P at draigBrady.com>
Date:   Fri Apr 4 02:14:32 2014 +0100

    remove runtime dependency on python-pbr

 ...-use-parallel-installed-versions-in-RHEL6.patch |    4 +-
 0002-Remove-dnsmasq-version-warning.patch          |    4 +-
 0003-remove-runtime-dependency-on-pbr.patch        |   31 ++++++++++++++++++++
 openstack-neutron.spec                             |    6 +++-
 4 files changed, 40 insertions(+), 5 deletions(-)
---
diff --git a/0001-use-parallel-installed-versions-in-RHEL6.patch b/0001-use-parallel-installed-versions-in-RHEL6.patch
index f52a583..e9ef13c 100644
--- a/0001-use-parallel-installed-versions-in-RHEL6.patch
+++ b/0001-use-parallel-installed-versions-in-RHEL6.patch
@@ -7,8 +7,8 @@ of webob sqlalchemy python-routes paste-deploy python-jinja2-26
 
 Change-Id: I290f56eae61c87893639a9e5d29f7fff760452cf
 ---
- neutron/__init__.py | 31 +++++++++++++++++++++++++++++++
- 1 file changed, 31 insertions(+)
+ neutron/__init__.py |   31 +++++++++++++++++++++++++++++++
+ 1 files changed, 31 insertions(+), 0 deletions(-)
 
 diff --git a/neutron/__init__.py b/neutron/__init__.py
 index b2c81bd..fef4d32 100644
diff --git a/0002-Remove-dnsmasq-version-warning.patch b/0002-Remove-dnsmasq-version-warning.patch
index 083a84d..ca796e0 100644
--- a/0002-Remove-dnsmasq-version-warning.patch
+++ b/0002-Remove-dnsmasq-version-warning.patch
@@ -4,8 +4,8 @@ Date: Fri, 13 Dec 2013 09:41:43 -0600
 Subject: [PATCH] Remove dnsmasq version warning
 
 ---
- neutron/agent/linux/dhcp.py | 11 +++++++----
- 1 file changed, 7 insertions(+), 4 deletions(-)
+ neutron/agent/linux/dhcp.py |   11 +++++++----
+ 1 files changed, 7 insertions(+), 4 deletions(-)
 
 diff --git a/neutron/agent/linux/dhcp.py b/neutron/agent/linux/dhcp.py
 index e650c00..fdac998 100644
diff --git a/0003-remove-runtime-dependency-on-pbr.patch b/0003-remove-runtime-dependency-on-pbr.patch
new file mode 100644
index 0000000..6e1287d
--- /dev/null
+++ b/0003-remove-runtime-dependency-on-pbr.patch
@@ -0,0 +1,31 @@
+From 0b9e9c8c1ec93d17ff978bbf6b6dcf75d4adb24a Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?P=C3=A1draig=20Brady?= <P at draigBrady.com>
+Date: Mon, 24 Mar 2014 14:50:23 +0000
+Subject: [PATCH] remove runtime dependency on pbr
+
+---
+ neutron/version.py |   13 +++++++++++--
+ 1 files changed, 11 insertions(+), 2 deletions(-)
+
+diff --git a/neutron/version.py b/neutron/version.py
+index 1819264..e5333c6 100644
+--- a/neutron/version.py
++++ b/neutron/version.py
+@@ -14,6 +14,15 @@
+ #    License for the specific language governing permissions and limitations
+ #    under the License.
+ 
+-import pbr.version
++class VersionInfo(object):
++    release = "RPMRELEASE"
++    version = "RPMVERSION"
+ 
+-version_info = pbr.version.VersionInfo('neutron')
++    def version_string(self):
++        return self.version
++
++    def release_string(self):
++        return self.release
++
++
++version_info = VersionInfo()
diff --git a/openstack-neutron.spec b/openstack-neutron.spec
index 2a91b90..43f3e64 100644
--- a/openstack-neutron.spec
+++ b/openstack-neutron.spec
@@ -54,6 +54,7 @@ Source90:	neutron-dist.conf
 #
 Patch0001: 0001-use-parallel-installed-versions-in-RHEL6.patch
 Patch0002: 0002-Remove-dnsmasq-version-warning.patch
+Patch0003: 0003-remove-runtime-dependency-on-pbr.patch
 
 BuildArch:	noarch
 
@@ -76,7 +77,6 @@ Requires:	dnsmasq-utils
 Requires:	python-neutron = %{version}-%{release}
 Requires:	openstack-utils
 Requires:	python-keystone
-Requires:	python-pbr
 
 Requires(post):		chkconfig
 Requires(postun):	initscripts
@@ -479,9 +479,12 @@ IPSec.
 
 %patch0001 -p1
 %patch0002 -p1
+%patch0003 -p1
 
 find neutron -name \*.py -exec sed -i '/\/usr\/bin\/env python/{d;q}' {} +
 
+sed -i 's/RPMVERSION/%{version}/; s/RPMRELEASE/%{release}/' neutron/version.py
+
 chmod 644 neutron/plugins/cisco/README
 
 # Let's handle dependencies ourseleves
@@ -1098,6 +1101,7 @@ fi
 %changelog
 * Fri Apr 04 2014 Pádraig Brady <pbrady at redhat.com> - 2014.1-0.13.rc1
 - Fix startup issue due to invalid group permissions, bz#1080560
+- Remove runtime dependency on python-pbr
 
 * Wed Apr 02 2014 Terry Wilson <twilson at redhat.com> 2014.1-0.9.rc1
 - Update to upstream 2014.1.rc1


More information about the scm-commits mailing list