Value for SWIFT_VERSION cannot be empty

前端 未结 4 906
遇见更好的自我
遇见更好的自我 2021-02-02 05:43

I have installed swift pods for the obj c project. I got this error when I was trying to build it.

I have gone through all the solutions like deleting derived

4条回答
  •  长发绾君心
    2021-02-02 06:39

    In case there is anybody else reading through this thread who has this same problem but was unable to solve it using the above answers, this may help:

    If you have a data model, you need to check that when you click on the data model, click on an entity, and bring up the file inspector, the "Code Generation" Language is properly set. In my case my whole app was written Objective-C, but was set here to Swift for some reason. This is another reason that Error will show up in the Issue Navigator.

    It's very important to clear the build folder after changing Code Generation Language. This can be done by pressing Command-Shift-K or by clicking Product->Clean Build Folder in the menu at the top of the screen.

    Check out this link for a picture of where to find the "Code Generation" option I'm talking about.

    Model.xcdatamodeld->File Inspector->Code Generation

提交回复
热议问题