diff options
author | Alexandru Croitor <alexandru.croitor@qt.io> | 2018-02-02 18:40:58 +0100 |
---|---|---|
committer | Alexandru Croitor <alexandru.croitor@qt.io> | 2018-02-06 10:48:08 +0000 |
commit | be8585ab74654943b461e81cbf0982d04a1ca9bb (patch) | |
tree | 7c61986df6cf77455ce7092db38b06c3629910e4 /setup.py | |
parent | 63fefd446910a921de7ebc350b9d62caecf0e730 (diff) |
Fix deployment of Qt libraries on macOS for standalone packages
Previously there was a selection process to choose which libraries
to copy over in order to save time and space by not copying libraries
for which there are no bindings.
The logic was incomplete, and it would be a burden to always update
it.
Instead it seems that WebEngine is the predominant time consumer
when copying, so just simplify the logic to the following:
1) If WebEngine bindings were generated, copy WebEngine Qt libraries
2) If not, don't
3) Copy all other Qt libraries
Task-number: PYSIDE-604
Change-Id: Iaa832b5281c9c328f056fd5f9f42e251d55be75f
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'setup.py')
-rw-r--r-- | setup.py | 22 |
1 files changed, 8 insertions, 14 deletions
@@ -1249,14 +1249,8 @@ class pyside_build(_build): def framework_dir_filter(dir_name, parent_full_path, dir_full_path): if '.framework' in dir_name: - if dir_name in ['QtWebEngine.framework', 'QtWebEngineCore.framework', \ - 'QtPositioning.framework', 'QtLocation.framework'] and \ - 'QtWebEngineWidgets.framework' in framework_built_modules: - return True - if dir_name in ['QtCLucene.framework'] and \ - 'QtHelp.framework' in framework_built_modules: - return True - if dir_name not in framework_built_modules: + if dir_name.startswith('QtWebEngine') and \ + 'QtWebEngineWidgets.framework' not in framework_built_modules: return False if dir_name in ['Headers', 'fonts']: return False @@ -1273,14 +1267,14 @@ class pyside_build(_build): ignore=["*.la", "*.a", "*.cmake", "*.pc", "*.prl"], dir_filter_function=framework_dir_filter) else: - if 'WebEngineWidgets' in built_modules: - built_modules.extend(['WebEngine', 'WebEngineCore', 'Positioning', 'Location']) - if 'Help' in built_modules: - built_modules.extend(['CLucene']) - prefixed_built_modules = ['*Qt5' + name + '*.dylib' for name in built_modules] + ignored_modules = [] + if 'WebEngineWidgets' not in built_modules: + ignored_modules.extend(['*Qt5WebEngine*.dylib']) + accepted_modules = ['*Qt5*.dylib'] copydir("{qt_lib_dir}", "{pyside_package_dir}/PySide2/Qt/lib", - filter=prefixed_built_modules, + filter=accepted_modules, + ignore=ignored_modules, recursive=True, vars=vars) if 'WebEngineWidgets' in built_modules: |