Skip to content

iOS Builds failing with "unsupported option '-mno-thumb' for target..." in Unity 2019, 2020

There an issue with building for iOS in Unity 2019 and 2020 where XCode fails with exception, “unsupported option ‘-mno-thumb’ for target…”, such as:

mno-thumbs-error-xcode

This issue is a Unity->Xcode output bug, described here:  https://discussions.unity.com/t/xcode-16-1-build-failing-unsupported-option-mno-thumb-for-target-arm64-apple-ios11-0/1563505/3 

To fix the issue:

  1. Locate the Build Settings:
    1. Open your project in Xcode.
    2. Select your project from the Project Navigator (left-hand side).
    3. Choose the Unity-iPhone target.
  2. Search for Other C Flags and Other C++ Flags:
    1. Go to the Build Settings tab.

    2. In the search bar at the top-right, type Other C Flags.

    3. Look for the entries under Custom Compiler Flags as shown below.

      mno-thumb-error

  3. Edit the Flags:
    1. Double-click the entry for each configuration (Debug, Release, etc.) where -mno-thumb appears.
    2. A text input box will appear showing the list of flags.
    3. Remove -mno-thumb from the list.
  4. Repeat for Other C++ Flags:
    1. Perform the same steps for Other C++ Flags.
  5. Save and Rebuild:
    1. Save the changes (it updates automatically in Xcode).
    2. Clean the project (Product > Clean Build Folder or Cmd+Shift+K).
    3. Rebuild the project.