As captain Redmuff said,
I made a mistake. After several attempts, I see that with the -all_load linker flag it works even for importing categories. My mistake was in my main header file: poor import, lack of some things, etc. And finally, do not restart my project after the -all_load flag is -all_load .
Now I'm in myFramework.h :
#import "MyCategory+Helper.h" #import "MyOtherCategory+Helper.h" #import "AClass.h" ...
In my project, where I use the framework:
1 / Set "Other linker flag" to -all_load (reload -all_load if necessary)
2 / Just #import <myFramework/myFramework.h> in myProjectApp-Prefix.pch for example
Then I do not need to import all other things into my project. Everything seems OK, despite the need to restart Xcode for the first time after adding my framework.
Thanks CaptainRedmuff, I already tested your solution, but in vain. After additional tests, this is normal!
* EDIT Everything works fine until I move on to one of my classes that use one of my categories. Xcode will indicate that I have an error, since this category does not exist. Same problem when I clear my code: ((
There is no visible interface for ... declares a selector ...
** EDIT If I import <myFrameWork/myFramework> into myProjectApp-Prefix.pch but not in #ifdef __OBJC__ conditional , this is normal.
Pebie
source share