mirror of
https://github.com/scylladb/scylladb.git
synced 2026-05-24 00:32:15 +00:00
relocatable python: Be more permissive with mime type checking
Fedora28 python magic used to return a x-sharedlib mime type for .so files. Fedora29 changed that to x-pie-executable, so the libraries are no longer relocated. Let's be more permissive and relocate everything that starts with application/. Fixes #4396 Signed-off-by: Glauber Costa <glauber@scylladb.com> Message-Id: <20190404140929.7119-1-glauber@scylladb.com>
This commit is contained in:
committed by
Avi Kivity
parent
882ea9caf0
commit
2305cc88f3
@@ -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 == 'application/x-sharedlib':
|
||||
if m and m.mime_type.startswith('application/'):
|
||||
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
|
||||
|
||||
Reference in New Issue
Block a user