From 8719d26fd030b37dc4335e0e7e63e5b468073ebd Mon Sep 17 00:00:00 2001 From: Monty Taylor Date: Thu, 8 Aug 2013 12:40:10 -0300 Subject: Don't attempt to patch eventlet without the patch Some projects, like horizon, do not carry the eventlet patch. Change-Id: I24ffad9ab7852be44e5d6c8805aa0a47647e21cc --- tools/install_venv_common.py | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/tools/install_venv_common.py b/tools/install_venv_common.py index 6ce5d00..0999e2c 100644 --- a/tools/install_venv_common.py +++ b/tools/install_venv_common.py @@ -202,12 +202,13 @@ class Fedora(Distro): RHEL: https://bugzilla.redhat.com/958868 """ - # Install "patch" program if it's not there - if not self.check_pkg('patch'): - self.die("Please install 'patch'.") - - # Apply the eventlet patch - self.apply_patch(os.path.join(self.venv, 'lib', self.py_version, - 'site-packages', - 'eventlet/green/subprocess.py'), - 'contrib/redhat-eventlet.patch') + if os.path.exists('contrib/redhat-eventlet.patch'): + # Install "patch" program if it's not there + if not self.check_pkg('patch'): + self.die("Please install 'patch'.") + + # Apply the eventlet patch + self.apply_patch(os.path.join(self.venv, 'lib', self.py_version, + 'site-packages', + 'eventlet/green/subprocess.py'), + 'contrib/redhat-eventlet.patch') -- cgit