johnno1962 / injectionforxcode

Runtime Code Injection for Objective-C & Swift
MIT License
6.56k stars 565 forks source link

CocoaPod import error #20

Closed zackhsuan closed 10 years ago

zackhsuan commented 10 years ago

Hi

Thanks for your excellent work!

I have just encountered an error: when injecting the code, I got this error from the console: file included from /Users/zackhsuan/Documents/IMP/2014_Projects/TimeFlows/iOSInjectionProject/InjectionBundle-Prefix.pch:17:
../Pods/ActiveRecord/Source/ActiveRecord.h:11:9: fatal error: ‘RubySugar/RubySugar.h’ file not found


import <RubySugar/RubySugar.h>


^ 1 error generated.



Actually the error happened when a pod imports another pod. No errors when run without injection.

Cheers

johnno1962 commented 10 years ago

Hi,

you need to adjust the "header include paths" of the iOSInjectionProject so that the .pch can find this header. Use "Product//Open Bundle Project”. Once you can get this sub-project to build you should be fine.

John