Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
985 views
in Technique[技术] by (71.8m points)

iphone - Flutter error: No profiles for ‘xxx’ were found: Xcode couldn’t find any iOS App Development provisioning profiles matching ‘xxx’

I am trying to test a Flutter app on an iPhone but I am getting the error shown below, This error happens during a?build?step.

error: No profiles for 'xxx' were found: Xcode couldn't find any iOS App Development provisioning profiles matching 'xxx'.  Automatic signing is disabled and unable to generate a profile. To enable automatic signing, pass -allowProvisioningUpdates to xcodebuild. (in target 'Runner' from project 'Runner')

on run I face this error

Launching lib/main.dart on Test’s iPhone in debug mode...
Warning: Missing build name (CFBundleShortVersionString).
Warning: Missing build number (CFBundleVersion).
Automatically signing iOS for device deployment using specified development team in Xcode project: FF3XTSVPAA
Action Required: You must set a build name and number in the pubspec.yaml file version field before submitting to the App Store.
Running Xcode build...
Xcode build done.                                            7.1s
Failed to build iOS app
Error output from Xcode build:
?
    2020-12-07 16:43:22.754 xcodebuild[58078:524500]  DTDeviceKit: deviceType from 49f62dac6f1da634e5d71981db4d591dc9126e4b was NULL
    2020-12-07 16:43:22.848 xcodebuild[58078:524500]  DTDeviceKit: deviceType from 49f62dac6f1da634e5d71981db4d591dc9126e4b was NULL
    2020-12-07 16:43:27.506 XCBBuildService[58089:524662] Failed to remove: /Users/pkimac/Library/Developer/Xcode/DerivedData/Runner-aeyppfmredercraizkomsbeyvogn/Build/Intermediates.noindex/XCBuildData/8a97fdf5f2a949e7c436c417eb175882-desc.xcbuild: unlink(/Users/pkimac/Library/Developer/Xcode/DerivedData/Runner-aeyppfmredercraizkomsbeyvogn/Build/Intermediates.noindex/XCBuildData/8a97fdf5f2a949e7c436c417eb175882-desc.xcbuild): No such file or directory (2)
    ** BUILD FAILED **


Xcode's output:
?
    note: Using new build system
    note: Planning build
    note: Constructing build description
    error: No profiles for 'com.duytq.flutterchatdemo' were found: Xcode couldn't find any iOS App Development provisioning profiles matching 'com.duytq.flutterchatdemo'. Automatic signing is disabled and unable to generate a profile. To enable automatic signing, pass -allowProvisioningUpdates to xcodebuild. (in target 'Runner' from project 'Runner')
    warning: The iOS deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 7.0, but the range of supported deployment target versions is 8.0 to 13.2.99. (in target 'abseil' from project 'Pods')
    warning: The iOS deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 4.3, but the range of supported deployment target versions is 8.0 to 13.2.99. (in target 'nanopb' from project 'Pods')
    warning: The iOS deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 7.0, but the range of supported deployment target versions is 8.0 to 13.2.99. (in target 'gRPC-C++-gRPCCertificates-Cpp' from project 'Pods')

Could not build the precompiled application for the device.
Error launching application on Test’s iPhone.

How do I make a provisioning profile? What should I do for my app run in iPhone?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

There are actually steps to solve this:

A provisioning profile is a binary file that you can use to run an app on a device and use its services while it is being developed. To distribute your app to the App Store, you need to create a Distribution Provisioning Profile in order to get it approved by Apple. In this case, your build will be signed with the Production gateway.?

To deploy your Flutter app to a physical iOS device you’ll need to set up physical device deployment in Xcode and an Apple Developer account. If your app is using Flutter plugins, you will also need the third-party CocoaPods dependency manager.

  1. Open the terminal and run these commands to install the tools for deploying Flutter apps to iOS devices. Install and set up CocoaPods by running the following commands:

    sudo gem install cocoapods
    
  2. Follow the Xcode signing flow to provision your project:

    a. Open the default Xcode workspace in your project by running open ios/Runner.xcworkspace in a terminal window from your Flutter project directory.

    b.Select the device you intend to deploy to in the device drop-down menu next to the run button.

    c.Select the Runner project in the left navigation panel.

    d.In the Runner target settings page, make sure your Development Team is selected. The UI varies depending on your version of Xcode.

    • For Xcode 11 and newer, look under Signing & Capabilities > Team.

    When you select a team, Xcode creates and downloads a Development Certificate, registers your device with your account, and creates and downloads a provisioning profile (if needed).

    • To start your first iOS development project, you might need to sign into Xcode with your Apple ID.

    enter image description here

    Development and testing is supported for any Apple ID. Enrolling in the Apple Developer Program is required to distribute your app to the App Store. For details about membership types, see Choosing a Membership.

    Then, go to the Settings app on the iOS device, select General > Device Management and trust your Certificate. For first time users, you may need to select General > Profiles > Device Management instead.

    • If automatic signing fails in Xcode, verify that the project’s General > Identity > Bundle Identifier value is unique.

    enter image description here

  3. Start your app by running flutter run or clicking the Run button in Xcode.

To create a provisioning profile, follow the instructions on the?Apple help page.

Download manual provisioning profiles, download the provisioning profile.

For more info, see: https://flutter.dev/docs/get-started/install/macos#ios-setup


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...