I asked a question here yesterday about HOWTO debug in a framework.
I have one networkLib
, and a usingLibDemo
project.
The answers suggest me to pull the networkLib
into usingLibDemo
so that I can debug in the source code.
Now I've tried :
- Output a framework from
networkLib
, and use the framework inusingLibDemo
. It works. - Copy all the source code of
networkLib
intousingLibDemo
, it works again. - Drag the
networkLib
project intousingLibDemo
project, set theHeader Search Paths
in theBuild Settings
and set theTarget Dependencies
in theBuild Phases
. It fails.
In #3 situation, the project is build successfully when using headers only. For example, I just use the protocol:
@interface ViewController : UIViewController <LoginUIDelegate>
@property (retain, nonatomic) IBOutlet UITextField *usernameText;
@property (retain, nonatomic) IBOutlet UITextField *passwordText;
@property (retain, nonatomic) IBOutlet UIButton *loginButton;
- (IBAction)loginBtnDidClick:(id)sender;
@end
But when I use the code in the .m
file :
[[LoginBizLogic sharedInstance] loginWithUsername:username password:password tokenLogin:NO uiDelegate:self];
Build failed like below :
The @interface
of LoginBizLogic, as well as LoginUIDelegate
, is defined in LoginBizLogic.h
file, but the @implementation
is in the 'LoginBizLogic.m' file.
I think the LoginBizLogic
is not linked properly, and the same with other Class, but I can not figure out where the problem is, or where to config.
Many thanks.