Update RestKit 'lcl_RK.h' file not found i

2019-01-04 14:29发布

I install RestKit v0.25.0 with CocoaPods v0.39 in Xcode 7.1 and have problem with imports. When I used CocoaPods v0.38.2 everything was amazing.
"RKHTTPUtilities.h" file not found. It solves after set recursive in headers search path for "${PODS_ROOT}/Headers/Public/RestKit". But I get this error 'lcl_RK.h' file not found in RKLog.h.

I also try do this.

2条回答
冷血范
2楼-- · 2019-01-04 15:06

I found only one not the best way. Add "$(PODS_ROOT)/RestKit/Vendor/LibComponentLogging/Core" in headers search path for project target.

Explain: lcl_RK.h file is in folder path RestKit/Vendor/LibComponentLogging/Core, all other files in folder RestKit/Code/. When CocoaPods generates Headers folder, it misses lcl_RK.h file.

查看更多
聊天终结者
3楼-- · 2019-01-04 15:06

If anyone is having problems with RestKit 0.26.0 and Cocoapods 1.0.1, in a Swift project using Xcode 7.3, hopefully this will help!

This solution worked at least on 2016-06-03, but since it uses specific git branches maybe these will be merged, so if this does not work for you please check if this git branches have been merged/moved/deleted.

Clean up before everything

Quit Xcode

rm -rf Pods
rm -rf MyApp.xcworkspace  
rm -rf ~/Library/Caches/CocoaPods
rm -rf ~/Library/Developer/Xcode/DerivedData

Use mcfedr's RestKit fork

Must be used together with "reachablility" branch of AFNetworking

pod 'AFNetworking', :git => 'https://github.com/mcfedr/AFNetworking.git', :branch => 'reachability'
pod 'RestKit', :git => 'https://github.com/mcfedr/RestKit.git', :branch => 'pods1'

Use module import syntax in Bridging Header

@import RestKit;

Now it should work!

查看更多
登录 后发表回答