我正在使用 ASI (ASIHTTPRequestASIDownloadCacheReachability等)请求。现在在我的项目中,我正在使用reachability.h.m文件。我添加了一个第三方库,并且在该库中我知道它们也在使用 ASI 库。
但是据我所知,他们使用的是ASIReachability类而不是Reachability。所以我也添加了.h文件。

我仍然收到链接器错误,内容为:

duplicate symbol _kInternetConnection in:

    /Users/goutham.v/Library/Developer/Xcode/DerivedData/My_TWCable-fyaebjpvvaprmgdgtirhzshodpky/Build/Intermediates/My TWCable.build/Debug-iphonesimulator/My TWCable.build/Objects-normal/i386/Reachability.o
    /Users/goutham.v/Desktop/SVN/TWC_BC/12Mar2014_TWCBC/weandsf/iphonesimulator/libWeANDSFLibrary.a(ASIReachability.o)

duplicate symbol _kLocalWiFiConnection in:

    /Users/goutham.v/Library/Developer/Xcode/DerivedData/My_TWCable-fyaebjpvvaprmgdgtirhzshodpky/Build/Intermediates/My TWCable.build/Debug-iphonesimulator/My TWCable.build/Objects-normal/i386/Reachability.o
    /Users/goutham.v/Desktop/SVN/TWC_BC/12Mar2014_TWCBC/weandsf/iphonesimulator/libWeANDSFLibrary.a(ASIReachability.o)

duplicate symbol _kReachabilityChangedNotification in:

    /Users/goutham.v/Library/Developer/Xcode/DerivedData/My_TWCable-fyaebjpvvaprmgdgtirhzshodpky/Build/Intermediates/My TWCable.build/Debug-iphonesimulator/My TWCable.build/Objects-normal/i386/Reachability.o
    /Users/goutham.v/Desktop/SVN/TWC_BC/12Mar2014_TWCBC/weandsf/iphonesimulator/libWeANDSFLibrary.a(ASIReachability.o)
duplicate symbol _kConnectionDown in:

    /Users/goutham.v/Library/Developer/Xcode/DerivedData/My_TWCable-fyaebjpvvaprmgdgtirhzshodpky/Build/Intermediates/My TWCable.build/Debug-iphonesimulator/My TWCable.build/Objects-normal/i386/Reachability.o
    /Users/goutham.v/Desktop/SVN/TWC_BC/12Mar2014_TWCBC/weandsf/iphonesimulator/libWeANDSFLibrary.a(ASIReachability.o)
ld: 4 duplicate symbols for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)

请帮我。感谢您。

最佳答案

您收到重复符号错误。因此,您必须搜索此字符串_kConnectionDown_kReachabilityChangedNotification_kLocalWiFiConnection_kInternetConnection,并从文件中删除重复项。我认为,您可以两次导入Reachability类,一种是从libWeANDSFLibrary.a导入的,另一种是从ASI导入的。检查一下。希望能帮到您。

关于ios - 由于libWeANDSFLibrary.a(ASIReachability.o)​​而导致的重复符号链接(symbolic link)器错误,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/22451795/

10-15 07:19
查看更多