GrumpyMelon
GrumpyMelon

Reputation: 313

iOS : cocoaPods lint issues while using framework

I put some frameworks into my pod project and it lint passed validation. The I add some files which import header files in this framework and it don't work, this is part of my podspec:

mojiPodsLibrary.subspec 'Service' do |service|
service.source_files = 'Pod/Classes/Service/**/*',
                       'Pod/Classes/Service/MojiWeather/Library/Framework/AMapFoundationKit.framework/Headers/*.h',
                       'Pod/Classes/Service/MojiWeather/Library/Framework/AMapLocationKit.framework/Headers/*.h',
                       'Pod/Classes/Service/MojiWeather/Library/Framework/AMapSearchKit.framework/Headers/*.h'
service.vendored_frameworks = 'Pod/Classes/Service/MojiWeather/Library/Framework/AMapFoundationKit.framework',
                              'Pod/Classes/Service/MojiWeather/Library/Framework/AMapLocationKit.framework',
                              'Pod/Classes/Service/MojiWeather/Library/Framework/AMapSearchKit.framework'
service.xcconfig = { 'LD_RUNPATH_SEARCH_PATHS' => 'Pod/Classes/Service/MojiWeather/Library/Framework' }

service.subspec 'MojiWeather' do |mojiWeather|
  mojiWeather.source_files = 'Pod/Classes/Service/MojiWeather/**/*'
  mojiWeather.subspec 'Location' do |location|
    #using AMap framework
    location.source_files = 'Pod/Classes/Service/MojiWeather/Location/**/*'
    location.public_header_files = 'Pod/Classes/Service/MojiWeather/Library/Framework/AMapFoundationKit.framework/Headers/*.h',
                       'Pod/Classes/Service/MojiWeather/Library/Framework/AMapLocationKit.framework/Headers/*.h',
                       'Pod/Classes/Service/MojiWeather/Library/Framework/AMapSearchKit.framework/Headers/*.h'
  end        
end

This is the error code : [MojiPodsLibrary/Service/MojiWeather,MojiPodsLibrary/Service/MojiWeather/Location] xcodebuild: /Users/jack/PodGit/Pod/Classes/Service/MojiWeather/Location/LocationManager.h:13:9: fatal error: 'AMapLocationKit/AMapLocationKit.h' file not found

The version of pod I am using is 0.39.0; Can someone help me with this please?

Upvotes: 0

Views: 141

Answers (1)

Raj Joshi
Raj Joshi

Reputation: 2669

You should update your Cocoapods to Cocoapods 1.1.0+ because some frameworks are required to build updated version.

Upvotes: 1

Related Questions