Class AMSupportURLConnectionDelegate is implemented in both ?? (0x204ba8188) and ?? (0x1145382b8). One of the two will be used. Which one is undefined
2,585
Solution 1
- Install Rosetta 2 on Your Mac M1 by executing this in terminal:
softwareupdate --install-rosetta
- Select the app(terminal) in the Finder.
- Right click on the app(terminal) and select Get Info.
- In General, check the Open using Rosetta check-box.
- Close the terminal Info.
- Quit terminal and open it again.
- Now in terminal write the following in front of your command:
arch -x86_64 [your command]
Credit: daniel.gindi gave a comment which allowed me to figure this out.
Solution 2
I have same issue and resolved by accident. Give it a try (not sure if this works)
flutter clean
rm ios/Podfile ios/Podfile.lock pubspec.lock
rm -rf ios/Pods ios/Runner.xcworkspace
Solution 3
I solved this issue yesterday;
Please check out your apple dev account on your xcode first, and run your project using xcode, and input your password, trust your certificate. After your xcode build success, you can run it on your idea (Android Studio) now.
Author by
Prasath
Updated on December 28, 2022Comments
-
Prasath over 1 year
I'm running the flutter project on M1(Apple Silicon). This project is working in the Apple Intel and Windows. Please see my error messages while I got in the
flutter run
Prasaths-MacBook-Pro:Foodom_ios prasathsivanathan$ flutter run Launching lib/main.dart on iPhone 8 in debug mode... Running Xcode build... Xcode build done. 1.6s Failed to build iOS app Error output from Xcode build: ↳ objc[20641]: Class AMSupportURLConnectionDelegate is implemented in both ?? (0x204ba8188) and ?? (0x113e842b8). One of the two will be used. Which one is undefined. objc[20641]: Class AMSupportURLSession is implemented in both ?? (0x204ba81d8) and ?? (0x113e84308). One of the two will be used. Which one is undefined. ** BUILD FAILED ** Xcode's output: ↳ In file included from /Users/prasathsivanathan/Desktop/Projects/Flutter/Test/Foodom_ios/ios/Pods/FirebaseAuth/FirebaseAuth/Sources/ Utilities/FIRAuthURLPresenter.m:24: /Users/prasathsivanathan/Desktop/Projects/Flutter/Test/Foodom_ios/ios/Pods/FirebaseAuth/FirebaseAuth/Sources/ Utilities/FIRAuthDefaultUIDelegate.h:18:24: error: 'TARGET_OS_WATCHOS' is not defined, evaluates to 0 [-Werror,-Wundef-prefix=TARGET_OS_] #if !TARGET_OS_OSX && !TARGET_OS_WATCHOS ^ 1 error generated. In file included from /Users/prasathsivanathan/Desktop/Projects/Flutter/Test/Foodom_ios/ios/Pods/FirebaseAuth/FirebaseAuth/Sources/ Utilities/FIRAuthDefaultUIDelegate.m:23: /Users/prasathsivanathan/Desktop/Projects/Flutter/Test/Foodom_ios/ios/Pods/FirebaseAuth/FirebaseAuth/Sources/ Utilities/FIRAuthDefaultUIDelegate.h:18:24: error: 'TARGET_OS_WATCHOS' is not defined, evaluates to 0 [-Werror,-Wundef-prefix=TARGET_OS_] #if !TARGET_OS_OSX && !TARGET_OS_WATCHOS ^ 1 error generated. note: Using new build system note: Building targets in parallel note: Planning build note: Analyzing workspace note: Constructing build description note: Build preparation complete warning: Capabilities for Signing & Capabilities may not function correctly because its entitlements use a placeholder team ID. To resolve this, select a development team in the Runner editor. (in target 'Runner' from project 'Runner') Could not build the application for the simulator. Error launching application on iPhone 8.
-
Dolphin about 2 yearsdid you found a solution to fix this problem? @Prasath
-
Prasath about 2 yearsas i searched in the internet, this is related to xcode developer sign in , check the certificate, stackoverflow.com/a/67159933/5359340
-
-
daniel.gindi almost 3 yearsM1 is a very good product for the developer. And the developer should have enough knowledge to understand that M1 is a first generation which means not all software has adjusted yet, and enough to run rosetta with
arch -x86_64 .... whatever command you want
-
martinseal1987 almost 3 years@daniel.gindi this is the worst case of developer gas lighting i think ive ever seen
-
daniel.gindi almost 3 years@martinseal1987 I do not know how to interpret your comment, but have you seen the original wording? I've never seen an "answer" so subjective and useless on SO in my life.