Changeset 194498 in webkit


Ignore:
Timestamp:
Jan 2, 2016 1:39:56 AM (8 years ago)
Author:
berto@igalia.com
Message:

[GTK] webkit 2.3.5 build failure with python 3.3.4
https://bugs.webkit.org/show_bug.cgi?id=128971

Reviewed by Michael Catanzaro.

Make sure that the stdin encoding is 'UTF-8' if using Python 3,
otherwise the build will break.

  • Scripts/cssmin.py:
Location:
trunk/Source/WebInspectorUI
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebInspectorUI/ChangeLog

    r194491 r194498  
     12016-01-02  Alberto Garcia  <berto@igalia.com>
     2
     3        [GTK] webkit 2.3.5 build failure with python 3.3.4
     4        https://bugs.webkit.org/show_bug.cgi?id=128971
     5
     6        Reviewed by Michael Catanzaro.
     7
     8        Make sure that the stdin encoding is 'UTF-8' if using Python 3,
     9        otherwise the build will break.
     10
     11        * Scripts/cssmin.py:
     12
    1132016-01-01  Devin Rousso  <dcrousso+webkit@gmail.com>
    214
  • trunk/Source/WebInspectorUI/Scripts/cssmin.py

    r176699 r194498  
    4444if __name__ == "__main__":
    4545    import sys
     46    if sys.version_info[0] == 3 and sys.stdin.encoding != 'UTF-8':
     47        import io
     48        sys.stdin = io.TextIOWrapper(sys.stdin.buffer, encoding='UTF-8')
    4649    sys.stdout.write(cssminify(sys.stdin.read()))
Note: See TracChangeset for help on using the changeset viewer.