在重新启动Xcode之前,XCConfig不会刷新 [英] XCConfig not refreshing until Xcode is restarted

查看:126
本文介绍了在重新启动Xcode之前,XCConfig不会刷新的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我希望有一个目标和几个编译方案,并且有一些编译器定义由方案的预执行脚本声明。

I want to have a single target and several compilation schemes, and have some compiler definitions declared by a pre-action script of the schemes.

预先行动脚本正在生成 comp.xcconfig 文件,该文件由[Release | Debug] Config.xcconfig #included。

The pre-action script is generating a comp.xcconfig file which is #included by [Release|Debug]Config.xcconfig.

我生成的 comp .xcconfig 保留此行:

GCC_PREPROCESSOR_DEFINITIONS = $(inherited) MY_TEST

我的应用程序包括以下行:

My app include these lines:

#ifdef MY_TEST
    #error ye
#else
    #error oy
#endif

使用上述配置进行编译会导致错误'ye',如预期的那样。

Compiling with the above configuration is resulting with error 'ye', as expected.


如果我然后更改 comp.xcconfig 为:

GCC_PREPROCESSOR_DEFINITIONS = $(inherited) MY_TEST1234

我还在'你'。但是如果我退出Xcode并重新启动它,我就是
得到预期的'oy'。

I'm still getting 'ye'. But if I quit Xcode and restart it, I'm getting the expected 'oy'.

我的问题:

有没有办法强制Xcode跟踪xcconfig文件的更改而无需退出Xcode?

Is there a way to force Xcode to track xcconfig files for changes without the need to exit Xcode?

推荐答案

根据Xcode 8.3测试版发行说明,此问题已解决:

According to Xcode 8.3 beta release notes, this problem is fixed:


•对xcconfig文件的更改不再需要重新启动Xcode以获取
效果。 (29805284)

• Changes to xcconfig files no longer require restarting Xcode to take effect. (29805284)

http://adcdownload.apple.com/Developer_Tools/Xcode_8.3_beta/Release_Notes_for_Xcode_8.3_beta.pdf

这篇关于在重新启动Xcode之前,XCConfig不会刷新的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆