Preface:
Individuals are not good at writing things, they go straight to the subject.
In fact, today will notice more targets this thing, is because in the study of a third-party library Fbmemoryprofiler, use, so search for some relevant information, here to record.
Probably everyone will encounter such a problem, the application upload, accidentally put the test environment package upload to the AppStore, the results point to the test server address, I have encountered this situation before, then no way, can only make a domain name mapping, Swap the domain name of the test server with the domain name of the official server. (The app was also forced to upgrade, think of no one.) or need to be tested, it is directly covered by the online version, or every time modified the Bundleid, in case that once forgot to change back ... It's pretty scary, too. So for all of the above, you can avoid this by adding multiple target methods.
All right, go directly to the link (the individual is too lazy): http://www.cocoachina.com/ios/20160331/15832.html
To write a little bit later, when using target and macro, I made a mistake: I used the definition of a macro definition to define the environment variable, which is customary to write:
#If Development instead of #IFDEF development cause each time to enter the ifdef inside because there are two target definitions inside, so this judgment is equivalent to useless, This is my side of the problem, record it, Memo.
iOS Multi-targets management