Failed to emit precompiled header for bridging header

后端 未结 20 1408
傲寒
傲寒 2020-11-30 04:35

I downloaded a project from GitHub, then pod the following files, some of which are written by OBJ-C and I used a bridge header.

pod ‘SnapKit’
pod ‘MJRefresh         


        
相关标签:
20条回答
  • 2020-11-30 05:20

    Deleting Podfile.lock and re-running pod install fixed this for me.

    0 讨论(0)
  • 2020-11-30 05:20

    In my case, I was building with the wrong scheme (Top-Left menu).

    0 讨论(0)
  • 2020-11-30 05:21

    I have tried all of the above steps mentioned in the answers but nothing worked for me, the problem was basically with the deployment target version for the project and in the podfile.

    In my project deployment target was 10.0 while in my podfile it was 11.0.

    0 讨论(0)
  • 2020-11-30 05:21

    I had same scenario, make sure for the file A that you have included in YourProjectName-Bridging-Header.h

    • if it uses some other class(s), then those other classes are also included before that File A
    0 讨论(0)
  • 2020-11-30 05:22

    Make sure you're opening the proper project workspace, otherwise, the Podfile may not have all the resources it needs to compile.

    I saw this same error on a project that had been working fine previously.

    I discovered that I had accidentally opened the ProjectName.xcodeproj file rather than the ProjectName.xcworkspace file. Opened the xcworkspace file and presto, project was working again!

    0 讨论(0)
  • 2020-11-30 05:24

    For my case I had a typo in folder name "Supporing FIles" instead of "Supporting Files".

    0 讨论(0)
提交回复
热议问题