Target aot_assembly_release failed: Exception: release/profile builds are only supported for physical devices. attempted to build for simulator
Asked Answered
A

2

10

I am new to Flutter iOS Development. I was trying to run my flutter app with three flavors dev, stage and prod. After running the application I am getting the following error.

Error (Xcode): Target aot_assembly_release failed: Exception: release/profile
builds are only supported for physical devices. attempted to build for
simulator.


Could not build the application for the simulator.
Error launching application on iPhone 14 Pro Max.

I have searched a lot, but haven't got any solutions over internet. It would be helpful if anyone will be able to help me with it.

PS - I want to run it on Simulator only. Thank You.

Archival answered 28/7, 2023 at 20:45 Comment(3)
Please provide enough code so others can better understand or reproduce the problem.Szechwan
I have the same issue. It works on physical devices, just not on simulator. Code doesn't really help here.Forerunner
Your problem has probably been resolved by now but for anyone else I want to suggest restarting your computer. No trying to make a joke, I had a similar issue twice and restarting resolved it.Abie
P
9

When you build on the simulator. The debug mode for the scheme is unique. If use release mode, the issue above will appear. enter image description here

Praefect answered 19/9, 2023 at 16:14 Comment(2)
how to solve this?Beguin
@Beguin Product -> Edit Scheme -> Build Configuration: Release-developmentKier
M
0

Running on an M2 Mac, this command resolved my issue:

sudo softwareupdate --install-rosetta --agree-to-license

Reference: Issue 85643

Mysticism answered 21/8, 2024 at 4:49 Comment(0)

© 2022 - 2025 — McMap. All rights reserved.