Skip to content

Commit

Permalink
[google_maps_flutter] Restore the arm64 workaround (#5915)
Browse files Browse the repository at this point in the history
Restores the workaround to exclude arm64 when building for simulator, which is still necessary for apps that support back to iOS 12.

Also removes all the example-app-level workarounds that manually excluded arm64 simulator, which were masking the failure in the first place, so that we don't accidentally break this again. The exception is the exclusions for the unit test targets, which need them in order to match the Flutter-tool-generated exclusion to the Runner, otherwise the unit tests can't build.

See flutter/flutter#94491
  • Loading branch information
stuartmorgan authored Jan 18, 2024
1 parent f2c1be0 commit 83c2c4d
Show file tree
Hide file tree
Showing 11 changed files with 17 additions and 22 deletions.
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 2.4.1

* Restores the workaround to exclude arm64 simulator builds, as it is still necessary for applications targeting iOS 12.

## 2.4.0

* Adds support for arm64 simulators.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,5 @@ end
post_install do |installer|
installer.pods_project.targets.each do |target|
flutter_additional_ios_build_settings(target)
target.build_configurations.each do |build_configuration|
build_configuration.build_settings['EXCLUDED_ARCHS[sdk=iphonesimulator*]'] = 'arm64 i386'
end
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@
97C146E61CF9000F007C117D /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 1430;
LastUpgradeCheck = 1510;
ORGANIZATIONNAME = "The Flutter Authors";
TargetAttributes = {
97C146ED1CF9000F007C117D = {
Expand Down Expand Up @@ -620,7 +620,6 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ENABLE_BITCODE = NO;
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = "i386 arm64";
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/Flutter",
Expand All @@ -645,7 +644,6 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ENABLE_BITCODE = NO;
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = "i386 arm64";
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/Flutter",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,5 @@ end
post_install do |installer|
installer.pods_project.targets.each do |target|
flutter_additional_ios_build_settings(target)
target.build_configurations.each do |build_configuration|
build_configuration.build_settings['EXCLUDED_ARCHS[sdk=iphonesimulator*]'] = 'arm64 i386'
end
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@
97C146E61CF9000F007C117D /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 1430;
LastUpgradeCheck = 1510;
ORGANIZATIONNAME = "The Flutter Authors";
TargetAttributes = {
97C146ED1CF9000F007C117D = {
Expand Down Expand Up @@ -546,7 +546,6 @@
CLANG_ENABLE_MODULES = YES;
DEVELOPMENT_TEAM = "";
ENABLE_BITCODE = NO;
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = "i386 arm64";
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/Flutter",
Expand All @@ -573,7 +572,6 @@
CLANG_ENABLE_MODULES = YES;
DEVELOPMENT_TEAM = "";
ENABLE_BITCODE = NO;
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = "i386 arm64";
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/Flutter",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1430"
LastUpgradeVersion = "1510"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,5 @@ end
post_install do |installer|
installer.pods_project.targets.each do |target|
flutter_additional_ios_build_settings(target)
target.build_configurations.each do |build_configuration|
build_configuration.build_settings['EXCLUDED_ARCHS[sdk=iphonesimulator*]'] = 'arm64 i386'
end
end
end
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@
97C146E61CF9000F007C117D /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 1430;
LastUpgradeCheck = 1510;
ORGANIZATIONNAME = "The Flutter Authors";
TargetAttributes = {
97C146ED1CF9000F007C117D = {
Expand Down Expand Up @@ -545,7 +545,6 @@
CLANG_ENABLE_MODULES = YES;
DEVELOPMENT_TEAM = "";
ENABLE_BITCODE = NO;
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = "i386 arm64";
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/Flutter",
Expand All @@ -572,7 +571,6 @@
CLANG_ENABLE_MODULES = YES;
DEVELOPMENT_TEAM = "";
ENABLE_BITCODE = NO;
"EXCLUDED_ARCHS[sdk=iphonesimulator*]" = "i386 arm64";
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"$(PROJECT_DIR)/Flutter",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1430"
LastUpgradeVersion = "1510"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,12 @@ Downloaded by pub (not CocoaPods).
s.dependency 'GoogleMaps', '< 9.0'
s.static_framework = true
s.platform = :ios, '12.0'
s.pod_target_xcconfig = { 'DEFINES_MODULE' => 'YES' }
# GoogleMaps 6.x does not support arm64 simulators, but also doesn't declare
# explicitly that it doesn't, so mark that here so that the Flutter tool knows
# to build the Runner for x86_64 instead. See https://github.com/flutter/flutter/issues/94491
# TODO(stuartmorgan): Remove EXCLUDED_ARCHS once this plugin requires iOS 13+,
# at which point Cocoapods will resolve to a version of GoogleMaps that has
# arm64 support.
s.pod_target_xcconfig = { 'DEFINES_MODULE' => 'YES', 'EXCLUDED_ARCHS[sdk=iphonesimulator*]' => 'arm64' }
s.resource_bundles = {'google_maps_flutter_ios_privacy' => ['Resources/PrivacyInfo.xcprivacy']}
end
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: google_maps_flutter_ios
description: iOS implementation of the google_maps_flutter plugin.
repository: https://github.com/flutter/packages/tree/main/packages/google_maps_flutter/google_maps_flutter_ios
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+maps%22
version: 2.4.0
version: 2.4.1

environment:
sdk: ^3.2.3
Expand Down

0 comments on commit 83c2c4d

Please sign in to comment.