'Failed to build iOS app. Error output from Xcode build (Flutter)
I had to update the main activity.java file in the android folder for a flutter project, and update it to V2, but I could not find it. So, I made it from scratch. When I did all that, I suddenly got an error when trying to run the app on the iOS and android emulators. I deleted the whole sdk, android studio and Xcode, but still the same problem. See code below.
What do I do?
Thx
Launching lib/main.dart on iPhone 13 in debug mode...
lib/main.dart:1
Xcode build done. 5.8s
Failed to build iOS app
Error output from Xcode build:
↳
** BUILD FAILED **
Xcode's output:
↳
Writing result bundle at path:
/var/folders/yl/zgnwjxdn5jlcqg8dby0bysj40000gn/T/flutter_tools.SDJ8Qi/flutter_ios_build_temp_dir3vqkEZ/temporary_xcresult_bundle
Improperly formatted define flag: Android
Failed to package /Users/user/1.Developer/Projects/The Complete Flutter UI Masterclass | iOS, Android, & Web/test_project.
Command PhaseScriptExecution failed with a nonzero exit code
note: Using new build system
note: Planning
note: Build preparation complete
note: Building targets in dependency order
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')
Result bundle written to path:
/var/folders/yl/zgnwjxdn5jlcqg8dby0bysj40000gn/T/flutter_tools.SDJ8Qi/flutter_ios_build_temp_dir3vqkEZ/temporary_xcresult_bundle
Could not build the application for the simulator.
Error launching application on iPhone 13.
Exited (sigterm)
Solution 1:[1]
Your project is in a folder that contains special characters ,, & and |. Especially the , is causing errors here.
The Complete Flutter UI Masterclass | iOS, Android, & Web
Simplify the folder name, clean your project and try again
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | passsy |
