0

I have two targets MyPTK and MyPTK copy, the MyPTK copy is a target which I have duplicated from MyPTK

#ifndef MyPTK
    [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(resetLogoutTimer) name:UITouchPhaseBegan object:nil];
#endif

but when I execute the app with MyPTK copy the control enters into above code, which suppose not too. I mean to say the control must not enter in that block.

  1. When Control will not enter into above target?

  2. What is actual behaviour, please explain.

  3. What will be difference between these targets when one is duplicated from another.

Thank You.

Nasir
  • 1,617
  • 2
  • 19
  • 34
  • Look at the "Build Settings" for both targets, specifically the "Other C Flags" settings. Check for the definition of `MyPTK`. – rmaddy Jan 29 '15 at 15:44
  • @rmaddy please can you provide of detailed information of your above answer ? – Nasir Feb 03 '15 at 09:12

1 Answers1

0

These two links helps me in solving my problem.

How to Create Both a Paid and Lite Version of an iPhone App

iOS Mobile Development: Using Xcode Targets to Reuse the Code

Along with MyPTK target was build alone but when I try to build MyPTK copy target, both MyPTK and MyPTK copy target used to build, so for building separate target I have unchecked the mark for target MyPTK copy in Edit Scheme --> MyPTK --> Build --> uncheck all the options for MyPTK copy such as Analyze,Test,Profile,Run,Archive.

And lastly Thanks to my friend Pabitra who helped me in solving this issue.

Please feel free to ask If you need any help from me regarding this kind of issues.

Nasir
  • 1,617
  • 2
  • 19
  • 34