components/openstack/horizon/patches/99-remove.xstatic.patch-proto
branchs11u3-sru
changeset 6035 c9748fcc32de
equal deleted inserted replaced
6016:a477397bba8b 6035:c9748fcc32de
       
     1 In-house patch to remove the imports of xstatic packages.  These
       
     2 imports are no longer needed as the static assets are collected at
       
     3 package time and the xstatic modules are not being delivered.
       
     4 
       
     5 NOTE:  This patch is applied AFTER gmake install has completed rather
       
     6 than during gmake prep.  We need the xstatic functionality to collect
       
     7 all the JavaScript libraries before packaging.
       
     8 
       
     9 --- /usr/lib/python2.7/vendor-packages/openstack_dashboard/static_settings.py.orig  2015-05-04 16:35:35.859239557 -0600
       
    10 +++ /usr/lib/python2.7/vendor-packages/openstack_dashboard/static_settings.py  2015-05-04 16:35:58.697407748 -0600
       
    11 @@ -17,99 +17,5 @@ distributions can edit or replace this f
       
    12  to match their distribution's standards.
       
    13  """
       
    14 
       
    15 -import xstatic.main
       
    16 -import xstatic.pkg.angular
       
    17 -import xstatic.pkg.angular_bootstrap
       
    18 -import xstatic.pkg.angular_lrdragndrop
       
    19 -import xstatic.pkg.angular_smart_table
       
    20 -import xstatic.pkg.bootstrap_datepicker
       
    21 -import xstatic.pkg.bootstrap_scss
       
    22 -import xstatic.pkg.d3
       
    23 -import xstatic.pkg.font_awesome
       
    24 -import xstatic.pkg.hogan
       
    25 -import xstatic.pkg.jquery
       
    26 -import xstatic.pkg.jquery_migrate
       
    27 -import xstatic.pkg.jquery_quicksearch
       
    28 -import xstatic.pkg.jquery_tablesorter
       
    29 -import xstatic.pkg.jquery_ui
       
    30 -import xstatic.pkg.jsencrypt
       
    31 -import xstatic.pkg.magic_search
       
    32 -import xstatic.pkg.rickshaw
       
    33 -import xstatic.pkg.spin
       
    34 -import xstatic.pkg.termjs
       
    35 -
       
    36 -
       
    37  def get_staticfiles_dirs(webroot='/'):
       
    38 -    STATICFILES_DIRS = [
       
    39 -        ('horizon/lib/angular',
       
    40 -            xstatic.main.XStatic(xstatic.pkg.angular,
       
    41 -                                 root_url=webroot).base_dir),
       
    42 -        ('horizon/lib/angular',
       
    43 -            xstatic.main.XStatic(xstatic.pkg.angular_bootstrap,
       
    44 -                                 root_url=webroot).base_dir),
       
    45 -        ('horizon/lib/angular',
       
    46 -            xstatic.main.XStatic(xstatic.pkg.angular_lrdragndrop,
       
    47 -                                 root_url=webroot).base_dir),
       
    48 -        ('horizon/lib/angular',
       
    49 -            xstatic.main.XStatic(xstatic.pkg.angular_smart_table,
       
    50 -                                 root_url=webroot).base_dir),
       
    51 -        ('horizon/lib/bootstrap_datepicker',
       
    52 -            xstatic.main.XStatic(xstatic.pkg.bootstrap_datepicker,
       
    53 -                                 root_url=webroot).base_dir),
       
    54 -        ('bootstrap',
       
    55 -            xstatic.main.XStatic(xstatic.pkg.bootstrap_scss,
       
    56 -                                 root_url=webroot).base_dir),
       
    57 -        ('horizon/lib',
       
    58 -            xstatic.main.XStatic(xstatic.pkg.d3,
       
    59 -                                 root_url=webroot).base_dir),
       
    60 -        ('horizon/lib',
       
    61 -            xstatic.main.XStatic(xstatic.pkg.hogan,
       
    62 -                                 root_url=webroot).base_dir),
       
    63 -        ('horizon/lib/font-awesome',
       
    64 -            xstatic.main.XStatic(xstatic.pkg.font_awesome,
       
    65 -                                 root_url=webroot).base_dir),
       
    66 -        ('horizon/lib/jquery',
       
    67 -            xstatic.main.XStatic(xstatic.pkg.jquery,
       
    68 -                                 root_url=webroot).base_dir),
       
    69 -        ('horizon/lib/jquery',
       
    70 -            xstatic.main.XStatic(xstatic.pkg.jquery_migrate,
       
    71 -                                 root_url=webroot).base_dir),
       
    72 -        ('horizon/lib/jquery',
       
    73 -            xstatic.main.XStatic(xstatic.pkg.jquery_quicksearch,
       
    74 -                                 root_url=webroot).base_dir),
       
    75 -        ('horizon/lib/jquery',
       
    76 -            xstatic.main.XStatic(xstatic.pkg.jquery_tablesorter,
       
    77 -                                 root_url=webroot).base_dir),
       
    78 -        ('horizon/lib/jsencrypt',
       
    79 -            xstatic.main.XStatic(xstatic.pkg.jsencrypt,
       
    80 -                                 root_url=webroot).base_dir),
       
    81 -        ('horizon/lib/magic_search',
       
    82 -            xstatic.main.XStatic(xstatic.pkg.magic_search,
       
    83 -                                 root_url=webroot).base_dir),
       
    84 -        ('horizon/lib',
       
    85 -            xstatic.main.XStatic(xstatic.pkg.rickshaw,
       
    86 -                                 root_url=webroot).base_dir),
       
    87 -        ('horizon/lib',
       
    88 -            xstatic.main.XStatic(xstatic.pkg.spin,
       
    89 -                                 root_url=webroot).base_dir),
       
    90 -        ('horizon/lib',
       
    91 -            xstatic.main.XStatic(xstatic.pkg.termjs,
       
    92 -                                 root_url=webroot).base_dir),
       
    93 -    ]
       
    94 -
       
    95 -    if xstatic.main.XStatic(xstatic.pkg.jquery_ui,
       
    96 -                            root_url=webroot).version.startswith('1.10.'):
       
    97 -        # The 1.10.x versions already contain the 'ui' directory.
       
    98 -        STATICFILES_DIRS.append(
       
    99 -            ('horizon/lib/jquery-ui',
       
   100 -             xstatic.main.XStatic(xstatic.pkg.jquery_ui,
       
   101 -                                  root_url=webroot).base_dir))
       
   102 -    else:
       
   103 -        # Newer versions dropped the directory, add it to keep the path the
       
   104 -        # same.
       
   105 -        STATICFILES_DIRS.append(
       
   106 -            ('horizon/lib/jquery-ui/ui',
       
   107 -             xstatic.main.XStatic(xstatic.pkg.jquery_ui,
       
   108 -                                  root_url=webroot).base_dir))
       
   109 -
       
   110 -    return STATICFILES_DIRS
       
   111 +    return []