-
设置pch
command+f 搜 prefix header 会出现

设置框1 值为yes。在框2中填写pch文件的正确路径。
-
添加预处理宏
command+f 搜preprocessor 会出现

在preprocessor macros 中,根据debug跟release添加需要支持的宏。
图片中的设置是: 为target的debug状态设置debug宏。如果在target中使用了某个宏,而没有在此设置,则默认为0。
-
也可用下面代码实现类似功能
宏.png
command+f 搜 prefix header 会出现
设置框1 值为yes。在框2中填写pch文件的正确路径。
command+f 搜preprocessor 会出现
在preprocessor macros 中,根据debug跟release添加需要支持的宏。
图片中的设置是: 为target的debug状态设置debug宏。如果在target中使用了某个宏,而没有在此设置,则默认为0。
也可用下面代码实现类似功能
本文标题:Xcode target build setting
本文链接:https://www.haomeiwen.com/subject/evsplttx.html
网友评论