Update file permissions for FlutterMacOS.framework (flutter/engine#52930)

During FlutterMacOS.framework engine universal fat framework creation, make sure the framework is `u=rwx,go=rx` when it's created.

There's a framework-side workaround in-flight https://github.com/flutter/flutter/pull/148580. 

However, this is still a good thing to do engine-side, particularly for add-to-app when they don't go through the `flutter assemble` tooling.

I'll also add a test around here, once this rolls 02a6c91e4d/packages/flutter_tools/test/host_cross_arch.shard/macos_content_validation_test.dart (L30)

Fixes https://github.com/flutter/flutter/issues/148354

[C++, Objective-C, Java style guides]: https://github.com/flutter/engine/blob/main/CONTRIBUTING.md#style
This commit is contained in:
Jenn Magder
2024-05-20 14:46:37 -07:00
committed by GitHub
parent 1579900629
commit dff60d8f55

View File

@@ -86,6 +86,8 @@ def main():
subprocess.check_call([
'lipo', arm64_dylib, x64_dylib, '-create', '-output', fat_framework_binary
])
# Make the framework readable and executable: u=rwx,go=rx.
subprocess.check_call(['chmod', '755', fat_framework_binary])
# Add group and other readability to all files.
versions_path = os.path.join(fat_framework, 'Versions')