Skip subdirectories in fix_apple_shared_install_name - #12732
memsharded merged 3 commits into
Conversation
Co-authored-by: Rubén Rincón Blanco <ruben@rinconblanco.es>
jcar87
left a comment
There was a problem hiding this comment.
On second thought, chances are this function shouldn't recursively find files as we would expect libdirs and bindirs to list all directories in the package_info() instead, in case there's actually relevant libraries in those subfolders
It is also important to consider that consumers via |
Co-authored-by: Francisco Ramírez <franchuti688@gmail.com>
| if binary_type not in ("DYLIB", "EXECUTE") or os.path.islink(file) or os.path.isdir(file): | ||
| return False | ||
| check_file = f"otool -hv {file}" | ||
| return binary_type in check_output_runner(check_file) |
There was a problem hiding this comment.
I suppose check_output_runner may raise, therefore any error from otool invocation (like, it failed to parse a particular file, or just missing), will result in failure to create a package.
should it have try/catch block here to return False in case of any errors?
Changelog: Bugfix: Fix issue in
fix_apple_shared_install_namewhen libdirs or bindirs have subfolders.Docs: Omit
Close: #12727
Co-authored-by: Rubén Rincón Blanco