ios - Can't use SDWebImage -
xcode: version 7.2
os x: 10.10.5
i'm newbie ios , trying use sdwebimage in objective-c following official installation guide, error:
undefined symbols architecture x86_64: "_objc_class_$_sdwebimagemanager", referenced from: objc-class-ref in viewcontroller.o ld: symbol(s) not found architecture x86_64 clang: error: linker command failed exit code 1 (use -v see invocation)
i downloaded zip file , unzip-ed it, , added file project.
also, added dependency "imageio.framework" , linker flag "-objc".
i've read these questions:
don't download , unzip. horrible way things. use cocoapods, carthage or @ least git submodules. "unzip way" makes code harder maintain: cannot know version imported (when go project in year), noone knows reference. people manually change source files, later won't able update newer version without losing these changes. have setup project manually, seems, troublesome (and many others, don't worry). easiest way fix it? use cocoapods.
to it, open console , type:
$ sudo gem install cocoapods
close project in xcode. open path .xcodeproj in console. type:
$ pod init
open .podfile. paste there pod 'sdwebimage', '~> 3.7'
. in console type:
$ pod install
when completes, open .xcodeworkspace. should working fine now.
Comments
Post a Comment