问题描述
我正在使用 ASI(ASIHTTPRequest
、ASIDownloadCache
、Reachability
等)请求.现在在我的项目中,我使用 reachability.h
和 .m
文件.我添加了一个第三方库,在那个库中我知道他们也在使用ASI 库.但据我所知,他们使用的是 ASIReachability
类而不是 Reachability
.所以我也添加了 .h
文件.
I am using ASI (ASIHTTPRequest
, ASIDownloadCache
, Reachability
etc) request. Now in my project, I am using reachability.h
and .m
file.I have added one third party library and in that library I came to know that they are also using ASI library.But as per my knowledge they are using ASIReachability
class instead of Reachability
. So I added that .h
file as well.
我仍然收到链接器错误,内容为:
Still I am getting linker error which says :
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
.检查这个.希望能帮到你.
You've receive duplicate symbol error. So you've to search this string _kConnectionDown
, _kReachabilityChangedNotification
, _kLocalWiFiConnection
, _kInternetConnection
, and remove duplication from files. I think, you may import Reachability
class twice, one from libWeANDSFLibrary.a
and another from ASI
. Check this. Hope, help you.
这篇关于由于 libWeANDSFLibrary.a(ASIReachability.o) 导致的重复符号链接器错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!