diff options
author | Viacheslav Tertychnyi <tvk537@gmail.com> | 2021-04-17 23:24:04 +0300 |
---|---|---|
committer | Viacheslav Tertychnyi <tvk537@gmail.com> | 2021-04-20 20:16:53 +0000 |
commit | 2a456e543926a7d907388a528afbcc66dbbcdf08 (patch) | |
tree | c080f4804ec1f17db4a7923694b8f8c3f6dedb6d /scripts | |
parent | 14cb593526c22c0c37bf51d71364338cea5318a5 (diff) |
Deploy: Use objdump for MinGW build
Change-Id: Icb22aaecf3ca010b49d04af2ead7fb627a40c1db
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/deployqt.py | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/scripts/deployqt.py b/scripts/deployqt.py index e032f45dec..ab105f308a 100755 --- a/scripts/deployqt.py +++ b/scripts/deployqt.py @@ -110,12 +110,14 @@ def is_debug(fpath): # bootstrap exception if coredebug.search(fpath): return True - try: + # try to use dumpbin (MSVC) or objdump (MinGW), otherwise ship all .dlls + if which('dumpbin'): output = subprocess.check_output(['dumpbin', '/imports', fpath]) - return coredebug.search(output.decode(encoding)) != None - except OSError: - # dumpbin is not there, maybe MinGW ? Just ship all .dlls. + elif which('objdump'): + output = subprocess.check_output(['objdump', '-p', fpath]) + else: return debug_build + return coredebug.search(output.decode(encoding)) != None def is_ignored_windows_file(use_debug, basepath, filename): ignore_patterns = ['.lib', '.pdb', '.exp', '.ilk'] |