Duplicate symbol issues

后端 未结 8 891
Happy的楠姐
Happy的楠姐 2020-12-24 00:22

During a refactor of an iOS project, I ran into this bear of a bug. During the linking phase, I get this message:

ld: duplicate symbol _OBJC_IVAR_$_Ti

相关标签:
8条回答
  • 2020-12-24 01:17

    I had this issue on the latest Xcode 4. Cause: I included file.m instead of file.h

    Possibly, you included TinCanViewController.m (should be TinCanViewController.h)

    0 讨论(0)
  • 2020-12-24 01:18

    I had this happen but my problem was related to merge issues from our repo. The .m file was listed twice in a spot that it should only have been listed once (within the project, but not within the file/group structure, so you could not see the issue in Xcode, only the error). The fix is opening the .pbxproj file inside your project file and locating the duplicate entry in that file. After deleting the duplicate the project built just fine.

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