diff options
author | Florian Bruhin <git@the-compiler.org> | 2016-08-02 15:55:24 +0200 |
---|---|---|
committer | Florian Bruhin <git@the-compiler.org> | 2016-08-02 15:56:40 +0200 |
commit | 11d7486f97574d814245623584cd2f732fcad28c (patch) | |
tree | d1fc427dd79d9216657111cde5521505b6beea2e | |
parent | 8e7a1d3d970ce4e2c48a0437841d11898c1ffb8d (diff) | |
download | qutebrowser-11d7486f97574d814245623584cd2f732fcad28c.tar.gz qutebrowser-11d7486f97574d814245623584cd2f732fcad28c.zip |
freeze.py: Copy plugin folders on Windows
This makes HTML5 video work.
Fixes #1068.
-rwxr-xr-x | scripts/dev/freeze.py | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/scripts/dev/freeze.py b/scripts/dev/freeze.py index 6c269e890..33de7e9ce 100755 --- a/scripts/dev/freeze.py +++ b/scripts/dev/freeze.py @@ -49,6 +49,16 @@ def get_egl_path(): r'PyQt5\libEGL.dll') +def get_plugin_folders(): + """Get the plugin folders to copy to the output.""" + if not sys.platform.startswith('win'): + return [] + plugin_dir = os.path.join(distutils.sysconfig.get_python_lib(), + 'PyQt5', 'plugins') + folders = ['audio', 'iconengines', 'mediaservice', 'printsupport'] + return [os.path.join(plugin_dir, folder) for folder in folders] + + def get_build_exe_options(skip_html=False): """Get the options passed as build_exe_options to cx_Freeze. @@ -81,6 +91,8 @@ def get_build_exe_options(skip_html=False): if egl_path is not None: include_files.append((egl_path, 'libEGL.dll')) + include_files += get_plugin_folders() + return { 'include_files': include_files, 'include_msvcr': True, |