diff --git a/TOOLS/osxbundle.py b/TOOLS/osxbundle.py index 1a9cfb4a6e..fc8379c748 100755 --- a/TOOLS/osxbundle.py +++ b/TOOLS/osxbundle.py @@ -40,7 +40,13 @@ def apply_plist_template(plist_file, version): print(line.rstrip().replace('${VERSION}', version)) def sign_bundle(binary_name): - sh('codesign --force --deep -s - ' + bundle_path(binary_name)) + sign_directories = ['Contents/Frameworks', 'Contents/MacOS'] + for dir in sign_directories: + resolved_dir = os.path.join(bundle_path(binary_name), dir) + for root, _dirs, files in os.walk(resolved_dir): + for f in files: + sh('codesign --force -s - ' + os.path.join(root, f)) + sh('codesign --force -s - ' + bundle_path(binary_name)) def bundle_version(src_path): version = 'UNKNOWN'