Duplicate Symbol Error in Objective-C build?

前端 未结 17 2044
礼貌的吻别
礼貌的吻别 2020-11-27 14:12

I got this error when I press build+debug:

ld: duplicate symbol .objc_class_name_BlogTableItemCell in /Users/fabian/Development/Workspaces/iphone_experiments         


        
17条回答
  •  伪装坚强ぢ
    2020-11-27 14:52

    In may case, I followed some instructions to build a newer version of Subversion which directed me to create this symbolic link:

    ln -s /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/ /Applications/Xcode.app/Contents/Developer/Toolchains/OSX10.10.xctoolchain
    

    Now I'm really a Windows guy so it wasn't immediately obvious to me - but removing the link fixed it for me (after restarting XCode):

    rm /Applications/Xcode.app/Contents/Developer/Toolchains/OSX10.10.xctoolchain
    

    Phew.

    (The actual error I got was the one described here: build error duplicate symbols arclite.o)

提交回复
热议问题