Search Issue Tracker

Fixed in 2017.3.0f3

Fixed in 2017.2.X



Found in


Issue ID




[iOS] Compile errors in generated Xcode project in UnityRendering.h and UnityInterface.h for unknown type name bool



Compile errors in generated Xcode project in UnityRendering.h and UnityInterface.h for unknown type name bool

Getting compile errors in Xcode (version 8.3.3 8E3004b) when building to iOS.

projectroot/build-ios/Classes/Unity/UnityRendering.h:166:1: Unknown type name 'bool'
projectroot/build-ios/Classes/Unity/UnityInterface.h:131:1: Unknown type name 'bool'

To repro:
1) Open attached project
2) Build for iOS
3) Build in Xcode
4) See compile errors

Reproduced: 2017.2.0b9

Comments (8)

  1. taxvi

    Jul 07, 2018 22:31

    2018.1.0b13 - was fine at first, then added bugsnag sdk and this happened.
    #include <stdbool.h> solved it for me, thanks guys ^_^

  2. ylen_sami

    Jul 04, 2018 13:43

    Please reopen! This is still occuring in Unity 2018.1.6f1.

  3. TDArlt

    Jun 12, 2018 11:57

    Having the issue in Unity 2018.1.4f1 as well. Adding #include <stdbool.h> solved it as well.

    However, the bool is only needed for some specific methods, a WWW-related method in my case. Probably only the "more-likely-depricated methods" are bools in these files?

    So probably everyone having the problem and planning to update the project in future: Check which methods exactly use them and think about using other ones.

    Nevertheless this IS a bug and should be fixed (again).

  4. syslord2k2

    Jun 08, 2018 12:41

    Automatic solution for cloud build and because it's more comfortable:

    public class PostProcessBuild
    public static void OnPostProcessBuild(BuildTarget target, string path)
    string unityInterfacePath = path + "/Classes/Unity/UnityInterface.h";
    if (File.Exists(unityInterfacePath))
    List<string> interfaceLines = File.ReadAllLines(unityInterfacePath).ToList();
    interfaceLines.Insert(0, "#include <stdbool.h>");
    StringBuilder sb = new StringBuilder();
    foreach (string s in interfaceLines)
    File.WriteAllText(unityInterfacePath, sb.ToString());
    Debug.LogError("UnityInterface.h doesn't exist");

  5. multimediamarkers

    May 31, 2018 12:03

    Having issue in 2018.1.1f1 also ...

  6. halilkayim

    May 24, 2018 18:17

    Having this issue in 2018.1.1f1.

  7. RyoZaizenGR

    May 09, 2018 06:16

    regression in 2018.1.0f2

  8. michael_lightweave

    Oct 06, 2017 05:27

    Still happening in 2017.2.0f1. Fixable by adding #include <stdbool.h> to the top of UnityRendering.h and UnityInterface.h

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.