Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Build fail when using SDWebImage

I am trying to use the classes of SDWebImage in my project.

I've added the classes to my project and when I try to build it I get 7 errors:

    Undefined symbols for architecture i386:
  "_OBJC_CLASS_$_MKAnnotationView", referenced from:
      l_OBJC_$_CATEGORY_MKAnnotationView_$_WebCache in MKAnnotationView+WebCache.o
  "_CGImageSourceCreateIncremental", referenced from:
      -[SDWebImageDownloader connection:didReceiveData:] in SDWebImageDownloader.o
  "_CGImageSourceUpdateData", referenced from:
      -[SDWebImageDownloader connection:didReceiveData:] in SDWebImageDownloader.o
  "_CGImageSourceCopyPropertiesAtIndex", referenced from:
      -[SDWebImageDownloader connection:didReceiveData:] in SDWebImageDownloader.o
  "_CGImageSourceCreateImageAtIndex", referenced from:
      -[SDWebImageDownloader connection:didReceiveData:] in SDWebImageDownloader.o
  "_kCGImagePropertyPixelHeight", referenced from:
      -[SDWebImageDownloader connection:didReceiveData:] in SDWebImageDownloader.o
  "_kCGImagePropertyPixelWidth", referenced from:
      -[SDWebImageDownloader connection:didReceiveData:] in SDWebImageDownloader.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)

I am new to XCode and Objective-c so I got no idea what this errors mean.

Anyone?

Thank you.

like image 725
gabsferreira Avatar asked Sep 06 '12 18:09

gabsferreira


1 Answers

Looks like you need to add MapKit and ImageIO to the project.

To do that:

  1. Click on the project at the top of the project navigator in Xcode.
  2. Select the 'Build Phases' tab.
  3. Open up the 'Link Binary with Libraries' box.
  4. Click the '+'.
  5. App MapKit and ImageIO frameworks.
like image 167
mattjgalloway Avatar answered Sep 19 '22 06:09

mattjgalloway