Changeset 184856 in webkit


Ignore:
Timestamp:
May 26, 2015 4:26:51 AM (9 years ago)
Author:
commit-queue@webkit.org
Message:

[GTK] Expand wildcards inside generate-inspector-gresource-manifest.py
https://bugs.webkit.org/show_bug.cgi?id=138134

Patch by Milan Crha <mcrha@redhat.com> on 2015-05-26
Reviewed by Žan Doberšek.

Source/WebKit2:

  • PlatformGTK.cmake: Command line with expanded resources exceeds 32KB, which

is a limit on Windows. It's better to expand wildcards inside the python script.

Tools:

  • gtk/generate-inspector-gresource-manifest.py:

(get_filenames): Command line with expanded resources exceeds 32KB, which
is a limit on Windows. It's better to expand wildcards inside the python script.

Location:
trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit2/ChangeLog

    r184853 r184856  
     12015-05-26  Milan Crha  <mcrha@redhat.com>
     2
     3        [GTK] Expand wildcards inside generate-inspector-gresource-manifest.py
     4        https://bugs.webkit.org/show_bug.cgi?id=138134
     5
     6        Reviewed by Žan Doberšek.
     7
     8        * PlatformGTK.cmake: Command line with expanded resources exceeds 32KB, which
     9        is a limit on Windows. It's better to expand wildcards inside the python script.
     10
    1112015-05-25  Dan Bernstein  <mitz@apple.com>
    212
  • trunk/Source/WebKit2/PlatformGTK.cmake

    r184536 r184856  
    412412)
    413413
    414 file(GLOB InspectorFiles
     414set(InspectorFiles
    415415    ${CMAKE_SOURCE_DIR}/Source/WebInspectorUI/UserInterface/*.html
    416416    ${CMAKE_SOURCE_DIR}/Source/WebInspectorUI/UserInterface/Base/*.js
     
    427427    ${CMAKE_SOURCE_DIR}/Source/WebInspectorUI/UserInterface/Images/gtk/*.png
    428428    ${CMAKE_SOURCE_DIR}/Source/WebInspectorUI/UserInterface/Images/gtk/*.svg
     429    ${CMAKE_SOURCE_DIR}/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js
     430    ${DERIVED_SOURCES_WEBINSPECTORUI_DIR}/UserInterface/Protocol/InspectorBackendCommands.js
     431)
     432
     433file(GLOB InspectorFilesDependencies
     434    ${InspectorFiles}
    429435)
    430436
     
    435441    DEPENDS ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector/InspectorBackendCommands.js
    436442    COMMAND cp ${DERIVED_SOURCES_JAVASCRIPTCORE_DIR}/inspector/InspectorBackendCommands.js ${DERIVED_SOURCES_WEBINSPECTORUI_DIR}/UserInterface/Protocol/InspectorBackendCommands.js
    437 )
    438 
    439 list(APPEND InspectorFiles
    440     ${CMAKE_SOURCE_DIR}/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js
    441     ${DERIVED_SOURCES_WEBINSPECTORUI_DIR}/UserInterface/Protocol/InspectorBackendCommands.js
    442443)
    443444
     
    580581add_custom_command(
    581582    OUTPUT ${DERIVED_SOURCES_WEBKIT2GTK_DIR}/InspectorGResourceBundle.xml
    582     DEPENDS ${InspectorFiles}
     583    DEPENDS ${InspectorFilesDependencies}
    583584            ${TOOLS_DIR}/gtk/generate-inspector-gresource-manifest.py
    584585    COMMAND ${TOOLS_DIR}/gtk/generate-inspector-gresource-manifest.py --output=${DERIVED_SOURCES_WEBKIT2GTK_DIR}/InspectorGResourceBundle.xml ${InspectorFiles}
  • trunk/Tools/ChangeLog

    r184851 r184856  
     12015-05-26  Milan Crha  <mcrha@redhat.com>
     2
     3        [GTK] Expand wildcards inside generate-inspector-gresource-manifest.py
     4        https://bugs.webkit.org/show_bug.cgi?id=138134
     5
     6        Reviewed by Žan Doberšek.
     7
     8        * gtk/generate-inspector-gresource-manifest.py:
     9        (get_filenames): Command line with expanded resources exceeds 32KB, which
     10        is a limit on Windows. It's better to expand wildcards inside the python script.
     11
    1122015-05-25  Carlos Garcia Campos  <cgarcia@igalia.com>
    213
  • trunk/Tools/gtk/generate-inspector-gresource-manifest.py

    r173753 r184856  
    1717
    1818import argparse
     19import glob
    1920import os
    2021import sys
     
    2728    filenames = []
    2829
    29     for filename in args:
    30         base_dir_index = filename.rfind(BASE_DIR)
    31         if base_dir_index != -1:
    32             filenames.append(filename[base_dir_index + len(BASE_DIR):])
     30    for pattern in args:
     31        paths = glob.glob(pattern)
     32        for filename in paths:
     33            base_dir_index = filename.rfind(BASE_DIR)
     34            if base_dir_index != -1:
     35                name = filename[base_dir_index + len(BASE_DIR):]
     36                # The result should use forward slashes, thus make sure any os-specific
     37                # separator, added by the glob.glob() call, is properly replaced
     38                if os.sep != '/':
     39                    name = name.replace(os.sep, '/')
     40                filenames.append(name)
    3341    return filenames
    3442
Note: See TracChangeset for help on using the changeset viewer.