From b8accc6baf0a095369694ab57111b7d87e66bb7b Mon Sep 17 00:00:00 2001
From: Thomas Goirand <thomas@goirand.fr>
Date: Fri, 17 May 2013 08:18:36 +0000
Subject: [PATCH] Added fix-package-version-detection-when-building-doc.patch

Rewritten-From: 03942ef3e7f691d63b986eb098a6d2794e44c6d2
---
 ...-version-detection-when-building-doc.patch | 25 +++++++++++++++++++
 trusty/debian/patches/series                  |  1 +
 2 files changed, 26 insertions(+)
 create mode 100644 trusty/debian/patches/fix-package-version-detection-when-building-doc.patch

diff --git a/trusty/debian/patches/fix-package-version-detection-when-building-doc.patch b/trusty/debian/patches/fix-package-version-detection-when-building-doc.patch
new file mode 100644
index 0000000..55f91ca
--- /dev/null
+++ b/trusty/debian/patches/fix-package-version-detection-when-building-doc.patch
@@ -0,0 +1,25 @@
+Description: Fixes version detection when building docs
+Author: Thomas Goirand <zigo@debian.org>
+Forwarded: no
+Last-Update: 2013-05-17
+
+--- horizon-2013.1.1.orig/openstack_dashboard/openstack/common/version.py
++++ horizon-2013.1.1/openstack_dashboard/openstack/common/version.py
+@@ -19,6 +19,7 @@ Utilities for consuming the version from
+ """
+ 
+ import pkg_resources
++import os
+ 
+ 
+ class VersionInfo(object):
+@@ -54,6 +55,9 @@ class VersionInfo(object):
+         if self.release is None:
+             self.release = self._get_version_from_pkg_resources()
+ 
++        if self.release is None:
++            self.release = os.environ.get("OSLO_PACKAGE_VERSION", None)
++
+         return self.release
+ 
+     def version_string(self):
diff --git a/trusty/debian/patches/series b/trusty/debian/patches/series
index 89e6f35..877920a 100644
--- a/trusty/debian/patches/series
+++ b/trusty/debian/patches/series
@@ -1,2 +1,3 @@
 fix-dashboard-django-wsgi.patch
 fix-dashboard-manage.patch
+fix-package-version-detection-when-building-doc.patch
-- 
2.45.2