[python-saharaclient/f20] adding patch to remove pbr runtime dep
Michael McCune
mimccune at fedoraproject.org
Tue May 6 14:44:00 UTC 2014
commit bd7edb232e4993dbc11517abc7fc6646c977308d
Author: Michael McCune <mimccune at redhat.com>
Date: Mon May 5 13:48:13 2014 -0400
adding patch to remove pbr runtime dep
0001-remove-runtime-dep-on-python-pbr.patch | 21 +++++++++++++++++++++
python-saharaclient.spec | 16 ++++++++++++++--
2 files changed, 35 insertions(+), 2 deletions(-)
---
diff --git a/0001-remove-runtime-dep-on-python-pbr.patch b/0001-remove-runtime-dep-on-python-pbr.patch
new file mode 100644
index 0000000..cb842ef
--- /dev/null
+++ b/0001-remove-runtime-dep-on-python-pbr.patch
@@ -0,0 +1,21 @@
+--- saharaclient/version.py 2014-05-05 09:18:09.682115488 -0400
++++ saharaclient/version.py 2014-05-05 09:34:46.248635372 -0400
+@@ -13,6 +13,16 @@
+ # See the License for the specific language governing permissions and
+ # limitations under the License.
+
+-from pbr import version
+
+-version_info = version.VersionInfo('python-saharaclient')
++class VersionInfo(object):
++ release = 'REDHAT_SAHARACLIENT_RELEASE'
++ version = 'REDHAT_SAHARACLIENT_VERSION'
++
++ def version_string(self):
++ return self.version
++
++ def release_string(self):
++ return self.release
++
++
++version_info = VersionInfo()
diff --git a/python-saharaclient.spec b/python-saharaclient.spec
index 6516753..7ee0b5e 100644
--- a/python-saharaclient.spec
+++ b/python-saharaclient.spec
@@ -6,14 +6,14 @@
Name: python-saharaclient
Version: 0.7.0
-Release: 1%{?dist}
+Release: 3%{?dist}
Provides: python-savannaclient = %{version}-%{release}
Obsoletes: python-savannaclient <= 0.5.0-2
Summary: Client library for OpenStack Sahara API
License: ASL 2.0
URL: https://launchpad.net/sahara
Source0: http://tarballs.openstack.org/python-saharaclient/python-saharaclient-%{version}.tar.gz
-
+Patch0001: 0001-remove-runtime-dep-on-python-pbr.patch
BuildArch: noarch
BuildRequires: python-setuptools
@@ -36,6 +36,12 @@ Python client library for interacting with OpenStack Sahara API.
%prep
%setup -q -n %{name}-%{version}
+
+%patch0001 -p0
+
+sed -i s/REDHAT_SAHARACLIENT_VERSION/%{version}/ saharaclient/version.py
+sed -i s/REDHAT_SAHARACLIENT_RELEASE/%{release}/ saharaclient/version.py
+
rm -rf python_saharaclient.egg-info
rm -rf test-requirements.txt
@@ -62,6 +68,12 @@ rm -rf test-requirements.txt
%changelog
+* Mon May 05 2014 Michael McCune <mimccune at redhat> - 0.7.0-3
+- Changing the version/release temp for patch
+
+* Mon May 05 2014 Michael McCune <mimccune at redhat> - 0.7.0-2
+- Adding patch to remove runtime pbr dep
+
* Thu Apr 3 2014 Michael McCune <mimccune at redhat> - 0.7.0-1
- 0.7.0 release and rename from python-savannaclient
More information about the scm-commits
mailing list