Include not found compile error in Xcode 4.2

前端 未结 4 958
深忆病人
深忆病人 2020-12-16 13:38

I\'m getting include not found compile error in XCode. I have an iOS app project that i use Objective-c and c++ as mix.

Initially, i created one .h file and one .c

4条回答
  •  一生所求
    2020-12-16 14:19

    So I was having this issue with the Cocoapods library Bypass and none of these solutions did anything. The problem was with a file which Cocoapods creates called an umbrella header. This is located in /Support Files/-umbrella.h. Delete it, and it should build just fine.

    Now for the explanation of why this is necessary: the umbrella header is mixing both C++ and Objective-C code directly in a header which is a big no-no apparently and ends up completely breaking the C++ imports. By removing it (which seems to have no effect?) this conflicting import which Cocoapods unknowingly created will go away.

提交回复
热议问题