如何设置CGBITMAP_CONTEXT_LOG_ERRORS环境变量?

时间:2021-07-10 22:51:09

While using CGBitmapContextCreate I get error in XCode

在使用CGBitmapContextCreate时,在XCode中会出现错误

CGBitmapContextCreate: unsupported parameter combination: set CGBITMAP_CONTEXT_LOG_ERRORS environmental variable to see the details

不支持的参数组合:设置CGBITMAP_CONTEXT_LOG_ERRORS环境变量来查看详细信息

How can I set this var?

如何设置这个var?

I tried launchctl setenv CGBITMAP_CONTEXT_LOG_ERRORS /Users/user/Documents/cgbitmap_errors.log and launchctl setenv CGBITMAP_CONTEXT_LOG_ERRORS 1 and restarting XCode with no success.

我尝试了launchctl setenv CGBITMAP_CONTEXT_LOG_ERRORS /Users/user/Documents/cgbitmap_errors。日志和launchctl setenv CGBITMAP_CONTEXT_LOG_ERRORS 1并重新启动XCode,但没有成功。

I also tried combination with defaults write com.apple.dt.Xcode UseSanitizedBuildSystemEnvironment -bool NO, no success too

我还尝试了与默认写入com.apple.dt的组合。Xcode使用了自动化的构建系统环境——bool不,也不成功

I restarted computer too

我也重新启动电脑

1 个解决方案

#1


12  

Environmental variables can be set in the product scheme editor (in Xcode) like shown in the screenshot:

环境变量可以设置在产品方案编辑器(Xcode)中,如屏幕截图所示:

Product > Scheme > Edit Scheme... (⌘<) 如何设置CGBITMAP_CONTEXT_LOG_ERRORS环境变量?

产品>方案>编辑方案…(⌘<)

#1


12  

Environmental variables can be set in the product scheme editor (in Xcode) like shown in the screenshot:

环境变量可以设置在产品方案编辑器(Xcode)中,如屏幕截图所示:

Product > Scheme > Edit Scheme... (⌘<) 如何设置CGBITMAP_CONTEXT_LOG_ERRORS环境变量?

产品>方案>编辑方案…(⌘<)