From 5f437be1b56ddeab0c6148e61a3d3ba64c5a86b7 Mon Sep 17 00:00:00 2001 From: DreamPiggy Date: Mon, 25 Mar 2024 16:15:01 +0800 Subject: [PATCH] Fix the podspec issue for compatible header search path The old libwebp CocoaPods (maybe 1.0) contains issues for public headers --- SDWebImageWebPCoder.podspec | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/SDWebImageWebPCoder.podspec b/SDWebImageWebPCoder.podspec index 4d3cc13..a548240 100644 --- a/SDWebImageWebPCoder.podspec +++ b/SDWebImageWebPCoder.podspec @@ -21,12 +21,13 @@ This is a SDWebImage coder plugin to support WebP image. s.source_files = 'SDWebImageWebPCoder/Classes/**/*', 'SDWebImageWebPCoder/Private/*.h', 'SDWebImageWebPCoder/Module/SDWebImageWebPCoder.h' s.private_header_files = 'SDWebImageWebPCoder/Private/*.h' s.xcconfig = { - 'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) SD_WEBP=1', - 'USER_HEADER_SEARCH_PATHS' => '$(inherited) $(SRCROOT)/libwebp/src' + 'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) SD_WEBP=1' } s.watchos.xcconfig = { - 'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) SD_WEBP=1 WEBP_USE_INTRINSICS=1', - 'USER_HEADER_SEARCH_PATHS' => '$(inherited) $(SRCROOT)/libwebp/src' + 'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) SD_WEBP=1 WEBP_USE_INTRINSICS=1' + } + s.pod_target_xcconfig = { + 'USER_HEADER_SEARCH_PATHS' => '$(PODS_ROOT)/libwebp/src' } s.framework = 'CoreGraphics' s.dependency 'SDWebImage/Core', '~> 5.17'