dependencies - Can xcode pass compile flags to depended target from the depending one? -


here case i'm faced when building mac app.

the project has 3 targets: target comprised of ui src code , produces final app; target b produces command-line test program executes unit tests(i'm not using auto generated xxxtests target); , target c comprised of backend src codes, , produces static library target , target b link to.

the problem target b need target c being built flag "-dzs_test", target need target b being built without flag. so, how set xcode project/target settings don't have change setting when switching building target , target b? because changing build setting causes git reporting unstaged files, feels unnecessary because want build different target.

i'm wondering if xcode can forward flag depending target depended target can let b forward "-dzs_test=1" c , let target forward "-dzs_test=0" c.

or there better way of dividing project different targets?

i googled , found many xcode build setting related articles don't share specific need project. in advance.

i end using 2 kernel targets, i.e. target c1, , c2 use same source code different compile flags , c1 build zs_test defined c2 not. target , b depend on whichever need.


Comments

Popular posts from this blog

javascript - Google App Script ContentService downloadAsFile not working -

javascript - Function overwritting -

php - Find a regex to take part of Email -