2012-07-12 05:14:29 +08:00
|
|
|
Pod::Spec.new do |s|
|
2013-01-16 19:10:45 +08:00
|
|
|
s.name = 'SDWebImage'
|
2019-12-27 14:42:54 +08:00
|
|
|
s.version = '4.4.8'
|
2016-08-27 02:35:37 +08:00
|
|
|
|
2018-02-01 12:54:38 +08:00
|
|
|
s.osx.deployment_target = '10.9'
|
2016-06-03 00:10:31 +08:00
|
|
|
s.ios.deployment_target = '7.0'
|
2015-10-31 00:36:10 +08:00
|
|
|
s.tvos.deployment_target = '9.0'
|
2016-06-10 12:28:09 +08:00
|
|
|
s.watchos.deployment_target = '2.0'
|
|
|
|
|
2013-01-16 19:10:45 +08:00
|
|
|
s.license = 'MIT'
|
|
|
|
s.summary = 'Asynchronous image downloader with cache support with an UIImageView category.'
|
2018-10-24 17:34:55 +08:00
|
|
|
s.homepage = 'https://github.com/SDWebImage/SDWebImage'
|
2013-01-16 19:10:45 +08:00
|
|
|
s.author = { 'Olivier Poitrey' => 'rs@dailymotion.com' }
|
2018-10-24 17:34:55 +08:00
|
|
|
s.source = { :git => 'https://github.com/SDWebImage/SDWebImage.git', :tag => s.version.to_s }
|
2012-07-12 05:14:29 +08:00
|
|
|
|
2013-06-08 13:31:36 +08:00
|
|
|
s.description = 'This library provides a category for UIImageView with support for remote ' \
|
2013-01-16 19:10:45 +08:00
|
|
|
'images coming from the web. It provides an UIImageView category adding web ' \
|
|
|
|
'image and cache management to the Cocoa Touch framework, an asynchronous ' \
|
|
|
|
'image downloader, an asynchronous memory + disk image caching with automatic ' \
|
|
|
|
'cache expiration handling, a guarantee that the same URL won\'t be downloaded ' \
|
|
|
|
'several times, a guarantee that bogus URLs won\'t be retried again and again, ' \
|
|
|
|
'and performances!'
|
2012-07-12 05:14:29 +08:00
|
|
|
|
2013-01-16 19:10:45 +08:00
|
|
|
s.requires_arc = true
|
2012-09-12 19:02:33 +08:00
|
|
|
s.framework = 'ImageIO'
|
2013-08-14 15:02:06 +08:00
|
|
|
|
|
|
|
s.default_subspec = 'Core'
|
2012-07-12 05:14:29 +08:00
|
|
|
|
2013-08-14 15:02:06 +08:00
|
|
|
s.subspec 'Core' do |core|
|
|
|
|
core.source_files = 'SDWebImage/{NS,SD,UI}*.{h,m}'
|
Feature: refactor decoding code and provide decoding plugin
- open the decoding/encoding procedures to the users
- switch from hardcoded decoding/encoding to pluginable decoders/encoders (builtin + user created)
- `SDWebImageCodersManager` is a singleton holding an array of `SDImageCoder` (protocol). Even though a singleton is not necesarily a good pattern, in this case it eliminates dealing with passing this array around
- uses a priority queue behind scenes, which means the latest added coders have priority.
- the priority is crucial when encoding/decoding something, we go through the list and ask each coder if they can handle the current data (see `canDecodeFromData:`, `canEncodeToFormat:`, `canIncrementallyDecodeFromData:`)
- each coder must conform to this protocol `SDImageCoder` describing all the required behavior for a coder
- we provide 3 built-in coders: `SDWebImageImageIOCoder` (for JPEG, PNG, TIFF), `SDWebImageGIFCoder` (for GIF), `SDWebImageWebPCoder` (for WebP and animated WebP)
- the user of SDWebImage can create custom coders by conforming to `SDImageCoder` and adding the coders to `SDWebImageCodersManager`. See `addCoder:` or `removeCoder:` or `coders` getter to get the array
- in order to preserve backwards compatibility, the UIImage categories were preserved, calling the new coders APIs described above
2017-10-17 00:52:18 +08:00
|
|
|
core.exclude_files = 'SDWebImage/UIImage+WebP.{h,m}', 'SDWebImage/SDWebImageWebPCoder.{h,m}'
|
2015-10-31 00:36:10 +08:00
|
|
|
core.tvos.exclude_files = 'SDWebImage/MKAnnotationView+WebCache.*'
|
2013-08-14 15:02:06 +08:00
|
|
|
end
|
2013-06-08 13:31:36 +08:00
|
|
|
|
2013-01-16 19:10:45 +08:00
|
|
|
s.subspec 'MapKit' do |mk|
|
2018-02-01 12:54:38 +08:00
|
|
|
mk.osx.deployment_target = '10.9'
|
2016-06-03 00:10:31 +08:00
|
|
|
mk.ios.deployment_target = '7.0'
|
2016-06-13 14:47:09 +08:00
|
|
|
mk.tvos.deployment_target = '9.0'
|
2013-01-16 19:10:45 +08:00
|
|
|
mk.source_files = 'SDWebImage/MKAnnotationView+WebCache.*'
|
|
|
|
mk.framework = 'MapKit'
|
2013-08-14 15:57:20 +08:00
|
|
|
mk.dependency 'SDWebImage/Core'
|
2013-01-16 19:10:45 +08:00
|
|
|
end
|
2013-08-14 15:02:06 +08:00
|
|
|
|
2016-06-01 15:10:46 +08:00
|
|
|
s.subspec 'GIF' do |gif|
|
2016-06-10 12:28:09 +08:00
|
|
|
gif.ios.deployment_target = '7.0'
|
2016-06-01 15:10:46 +08:00
|
|
|
gif.source_files = 'SDWebImage/FLAnimatedImage/*.{h,m}'
|
|
|
|
gif.dependency 'SDWebImage/Core'
|
|
|
|
gif.dependency 'FLAnimatedImage', '~> 1.0'
|
|
|
|
end
|
|
|
|
|
2013-08-14 15:02:06 +08:00
|
|
|
s.subspec 'WebP' do |webp|
|
Feature: refactor decoding code and provide decoding plugin
- open the decoding/encoding procedures to the users
- switch from hardcoded decoding/encoding to pluginable decoders/encoders (builtin + user created)
- `SDWebImageCodersManager` is a singleton holding an array of `SDImageCoder` (protocol). Even though a singleton is not necesarily a good pattern, in this case it eliminates dealing with passing this array around
- uses a priority queue behind scenes, which means the latest added coders have priority.
- the priority is crucial when encoding/decoding something, we go through the list and ask each coder if they can handle the current data (see `canDecodeFromData:`, `canEncodeToFormat:`, `canIncrementallyDecodeFromData:`)
- each coder must conform to this protocol `SDImageCoder` describing all the required behavior for a coder
- we provide 3 built-in coders: `SDWebImageImageIOCoder` (for JPEG, PNG, TIFF), `SDWebImageGIFCoder` (for GIF), `SDWebImageWebPCoder` (for WebP and animated WebP)
- the user of SDWebImage can create custom coders by conforming to `SDImageCoder` and adding the coders to `SDWebImageCodersManager`. See `addCoder:` or `removeCoder:` or `coders` getter to get the array
- in order to preserve backwards compatibility, the UIImage categories were preserved, calling the new coders APIs described above
2017-10-17 00:52:18 +08:00
|
|
|
webp.source_files = 'SDWebImage/UIImage+WebP.{h,m}', 'SDWebImage/SDWebImageWebPCoder.{h,m}'
|
2016-05-29 03:50:53 +08:00
|
|
|
webp.xcconfig = {
|
|
|
|
'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) SD_WEBP=1',
|
|
|
|
'USER_HEADER_SEARCH_PATHS' => '$(inherited) $(SRCROOT)/libwebp/src'
|
|
|
|
}
|
2016-08-27 00:52:44 +08:00
|
|
|
webp.watchos.xcconfig = {
|
|
|
|
'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) SD_WEBP=1 WEBP_USE_INTRINSICS=1',
|
|
|
|
'USER_HEADER_SEARCH_PATHS' => '$(inherited) $(SRCROOT)/libwebp/src'
|
|
|
|
}
|
2013-08-14 15:57:20 +08:00
|
|
|
webp.dependency 'SDWebImage/Core'
|
2019-02-26 21:57:41 +08:00
|
|
|
webp.dependency 'libwebp', '>= 0.5', '< 2.0'
|
2013-08-14 15:02:06 +08:00
|
|
|
end
|
2012-07-12 05:14:29 +08:00
|
|
|
end
|