diff --git a/scripts/create-relocatable-package-python3.py b/scripts/create-relocatable-package-python3.py index d4a2f047d0..0eac08afba 100755 --- a/scripts/create-relocatable-package-python3.py +++ b/scripts/create-relocatable-package-python3.py @@ -157,7 +157,7 @@ def copy_file_to_python_env(ar, f): ar.add(os.path.realpath(f), arcname=libfile) else: m = magic.detect_from_filename(f) - if m and m.mime_type.startswith('application/'): + if m and (m.mime_type.startswith('application/x-sharedlib') or m.mime_type.startswith('application/x-pie-executable')): fix_sharedlib(ar, f, libfile) else: # in case this is a directory that is listed, we don't want to include everything that is in that directory