A build only device cannot be used to run this target

后端 未结 21 2564
情深已故
情深已故 2020-12-25 09:25

I get this error when I trying to test an app.

A build only device cannot be used to run this target.

No supported iOS devices are available

21条回答
  •  春和景丽
    2020-12-25 09:44

    I encountered the same error message. Here's what I have experienced and did so far;

    Step 1: Check your target.

    My current target is IOS 13.2. From here, you will not see what versions you currently have on your machine.

    Step 2: Check available versions on your local

    • Click the Generic IOS Device

    • This will display a dropdown menu that contains a Download Simulators... selection
    • In case the Download Simulators... selection is not visible, you need to lower down your target. In my case, from 13.2 I made it 13.0 (This depends on your current XCode) then repeat the Step 2 again
    • From here, I can now see the Download Simulators... selection
    • Select it

    • You will now see what are the available versions you have
    • From here, you may choose to download or just use the version you have (The one that is selected)

    Step 3: Change your IOS target accordingly

    • Now that you already know what are the available versions of the simulator you have locally, you can now change the IOS target.
    • In my case I choose to use IOS 11 (Just for this sample)
    • Then I change the target

    • Again click the Generic IOS Device

    • From here, you can now select any simulator under that IOS

    I am not an expert, I just wanted to share my experience and I hope this can help someone.

提交回复
热议问题