Skip to content

Update App Clip for Xcode 15 and iOS 16+ - #2162

Merged
jmagman merged 1 commit into
flutter:mainfrom
jmagman:app-clip
Feb 16, 2024
Merged

jmagman merged 1 commit into
flutter:mainfrom
jmagman:app-clip

Conversation

@jmagman

@jmagman jmagman commented Feb 14, 2024 •

Copy link
Copy Markdown
Member
  1. Run flutter run on the project to pick up project automigrations.
  2. Set min version to iOS 16 to take advantage of the 15MB size limit (see App Clip uncompressed size is larger than 10MB flutter#71098 (comment))
  3. Other updates needed to avoid Xcode errors and warnings.

First introduced in #538
See also flutter/website#10145

Pre-launch Checklist

  • I read the Flutter Style Guide recently, and have followed its advice.
  • I signed the CLA.
  • I read the Contributors Guide.
  • I updated/added relevant documentation (doc comments with ///).
  • All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-devrel channel on Discord.

@jmagman jmagman self-assigned this Feb 14, 2024
<string>1.0</string>
<key>MinimumOSVersion</key>
<string>9.0</string>
<string>12.0</string>

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automigration from the flutter tool.

Comment thread ios_app_clip/ios/Podfile
@@ -1,5 +1,5 @@
# Uncomment this line to define a global platform for your project
# platform :ios, '9.0'
# platform :ios, '12.0'

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automigration from the flutter tool.

classes = {
};
objectVersion = 51;
objectVersion = 54;

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automigration from the flutter tool.

0A48A2562508B57F0036A529 /* Frameworks */,
0A48A2572508B57F0036A529 /* Resources */,
0A48A2792508C8F70036A529 /* Embed Flutter */,
1999EAF6C873AB834CA4DC07 /* [CP] Embed Pods Frameworks */,

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CocoaPods did this.

9705A1C41CF9048500538489 /* Embed Frameworks */,
3B06AD1E1E4923F5004D2608 /* Thin Binary */,
0A48A26E2508B57F0036A529 /* Embed App Clips */,
3B06AD1E1E4923F5004D2608 /* Thin Binary */,

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rearrange these to avoid a cycle error caused by Runner.app/Info.plist:

Cycle inside Runner; building could produce unreliable results.
Cycle details:
→ Target 'Runner' has copy command from 'Runner.app/AppClips/AppClip.app'
○ That command depends on command in Target 'Runner': script phase “Thin Binary”
○ Target 'Runner' has process command with output 'Runner.app/Info.plist'
○ Target 'Runner' has copy command from 'Runner.app/AppClips/AppClip.app'

CODE_SIGN_STYLE = Automatic;
DEVELOPMENT_TEAM = "";
ENABLE_BITCODE = NO;
FRAMEWORK_SEARCH_PATHS = (

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
IPHONEOS_DEPLOYMENT_TARGET = 16.0;

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Take advantage of 16.0 15MB App Clip size limit.

<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1020"
LastUpgradeVersion = "1530"

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Xcode did this.

import Flutter

@UIApplicationMain
@main

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Avoid UIApplicationMain deprecation flutter/flutter#143044

<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CADisableMinimumFrameDurationOnPhone</key>

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automigrations from flutter.

@vashworth vashworth left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@domesticmouse

Copy link
Copy Markdown
Contributor

Are you ready for this PR to land?

@jmagman

jmagman commented Feb 16, 2024

Copy link
Copy Markdown
Member Author

Are you ready for this PR to land?

Yup, thanks for reviewing, I wasn't sure who else to put as a reviewer. I'll merge (this wouldn't have caused the android-build failure, should I file a bug?)

@jmagman
jmagman merged commit 3aaa867 into flutter:main Feb 16, 2024
@jmagman
jmagman deleted the app-clip branch February 16, 2024 00:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants