components/openstack/horizon/patches/99-remove.xstatic.patch-proto
changeset 4196 d697072a92f5
parent 4049 150852e281c4
child 5405 66fd59fecd68
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/components/openstack/horizon/patches/99-remove.xstatic.patch-proto	Mon Apr 27 10:19:50 2015 -0500
@@ -0,0 +1,78 @@
+In-house patch to remove the imports of xstatic packages.  These
+imports are no longer needed as the static assets are collected at
+package time and the xstatic modules are not being delivered.
+
+NOTE:  This patch is applied AFTER gmake install has completed rather
+than during gmake prep.  We need the xstatic functionality to collect
+all the JavaScript libraries before packaging.
+
+--- a/usr/lib/python2.7/vendor-packages/openstack_dashboard/settings.py	2015-01-13 10:40:30.930622964 -0700
++++ b/usr/lib/python2.7/vendor-packages/openstack_dashboard/settings.py	2015-01-13 10:40:57.470743881 -0700
+@@ -22,21 +22,6 @@ import sys
+ import warnings
+
+ from django.utils.translation import ugettext_lazy as _
+-import xstatic.main
+-import xstatic.pkg.angular
+-import xstatic.pkg.bootstrap_datepicker
+-import xstatic.pkg.bootstrap_scss
+-import xstatic.pkg.d3
+-import xstatic.pkg.font_awesome
+-import xstatic.pkg.hogan
+-import xstatic.pkg.jquery
+-import xstatic.pkg.jquery_migrate
+-import xstatic.pkg.jquery_quicksearch
+-import xstatic.pkg.jquery_tablesorter
+-import xstatic.pkg.jquery_ui
+-import xstatic.pkg.jsencrypt
+-import xstatic.pkg.rickshaw
+-import xstatic.pkg.spin
+
+ from openstack_dashboard import exceptions
+
+@@ -148,45 +133,6 @@ STATICFILES_FINDERS = (
+     'compressor.finders.CompressorFinder',
+ )
+
+-STATICFILES_DIRS = [
+-    ('horizon/lib/angular',
+-        xstatic.main.XStatic(xstatic.pkg.angular).base_dir),
+-    ('horizon/lib/bootstrap_datepicker',
+-        xstatic.main.XStatic(xstatic.pkg.bootstrap_datepicker).base_dir),
+-    ('bootstrap',
+-        xstatic.main.XStatic(xstatic.pkg.bootstrap_scss).base_dir),
+-    ('horizon/lib',
+-        xstatic.main.XStatic(xstatic.pkg.d3).base_dir),
+-    ('horizon/lib',
+-        xstatic.main.XStatic(xstatic.pkg.hogan).base_dir),
+-    ('horizon/lib/font-awesome',
+-        xstatic.main.XStatic(xstatic.pkg.font_awesome).base_dir),
+-    ('horizon/lib/jquery',
+-        xstatic.main.XStatic(xstatic.pkg.jquery).base_dir),
+-    ('horizon/lib/jquery',
+-        xstatic.main.XStatic(xstatic.pkg.jquery_migrate).base_dir),
+-    ('horizon/lib/jquery',
+-        xstatic.main.XStatic(xstatic.pkg.jquery_quicksearch).base_dir),
+-    ('horizon/lib/jquery',
+-        xstatic.main.XStatic(xstatic.pkg.jquery_tablesorter).base_dir),
+-    ('horizon/lib/jsencrypt',
+-        xstatic.main.XStatic(xstatic.pkg.jsencrypt).base_dir),
+-    ('horizon/lib',
+-        xstatic.main.XStatic(xstatic.pkg.rickshaw).base_dir),
+-    ('horizon/lib',
+-        xstatic.main.XStatic(xstatic.pkg.spin).base_dir),
+-]
+-
+-
+-if xstatic.main.XStatic(xstatic.pkg.jquery_ui).version.startswith('1.10.'):
+-    # The 1.10.x versions already contain the 'ui' directory.
+-    STATICFILES_DIRS.append(('horizon/lib/jquery-ui',
+-        xstatic.main.XStatic(xstatic.pkg.jquery_ui).base_dir))
+-else:
+-    # Newer versions dropped the directory, add it to keep the path the same.
+-    STATICFILES_DIRS.append(('horizon/lib/jquery-ui/ui',
+-        xstatic.main.XStatic(xstatic.pkg.jquery_ui).base_dir))
+-
+ COMPRESS_PRECOMPILERS = (
+     ('text/scss', 'django_pyscss.compressor.DjangoScssFilter'),
+ )