[macOS] Enable universal binary builds by default (#100271)
This changes the default build architectures for Flutter macOS apps to x86_64 and arm64. Previously, we manually excluded arm64 builds via the EXCLUDE_ARCHS Xcode setting in Flutter's generated xcconfig file. This eliminates setting EXCLUDE_ARCHS during the build and updates the default architectures in the tool and in the macos_assemble.sh wrapper. Issue: https://github.com/flutter/flutter/issues/97681 Umbrella issue: https://github.com/flutter/flutter/issues/60113
This commit is contained in:
@@ -70,7 +70,7 @@ BuildApp() {
|
||||
"assemble"
|
||||
"--no-version-check"
|
||||
"-dTargetPlatform=darwin"
|
||||
"-dDarwinArchs=x86_64"
|
||||
"-dDarwinArchs=x86_64 arm64"
|
||||
"-dTargetFile=${target_path}"
|
||||
"-dBuildMode=${build_mode}"
|
||||
"-dTreeShakeIcons=${TREE_SHAKE_ICONS}"
|
||||
|
||||
@@ -116,9 +116,6 @@ def flutter_additional_macos_build_settings(target)
|
||||
configuration_engine_dir = build_configuration.type == :debug ? debug_framework_dir : release_framework_dir
|
||||
build_configuration.build_settings['FRAMEWORK_SEARCH_PATHS'] = "\"#{configuration_engine_dir}\" $(inherited)"
|
||||
|
||||
# ARM not yet supported https://github.com/flutter/flutter/issues/69221
|
||||
build_configuration.build_settings['EXCLUDED_ARCHS'] = 'arm64'
|
||||
|
||||
# When deleted, the deployment version will inherit from the higher version derived from the 'Runner' target.
|
||||
# If the pod only supports a higher version, do not delete to correctly produce an error.
|
||||
build_configuration.build_settings.delete 'MACOSX_DEPLOYMENT_TARGET' if inherit_deployment_target
|
||||
|
||||
Reference in New Issue
Block a user