如何在Xcode中删除CLANG_CXX_LIBRARY行 [英] how to delete CLANG_CXX_LIBRARY row in xcode

查看:188
本文介绍了如何在Xcode中删除CLANG_CXX_LIBRARY行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试将gcc-4.8与xcode一起使用,并按照

I am trying to use gcc-4.8 with xcode and followed the steps in Integrating gcc 4.8 with Xcode 4.x

停留在要求删除CLANG_CXX_LIBRARY行的最后一步.删除按钮似乎无济于事.有指针吗?

Am stuck at the last step which asks to delete the CLANG_CXX_LIBRARY row. Delete button doesn't seem to help. ANy pointers?

此处报告了确切的问题

The exact problem is reported here http://www.blogosfera.co.uk/2013/08/how-to-suppress-xcode-emitting-stdlib-flag/

我正在尝试按照以下步骤从Xcode中使用GCC 4.8进行构建(仅使用4.8版本而不是4.7版本).

I am attempting to build using GCC 4.8 from within Xcode, following this procedure (only using version 4.8 instead of 4.7).

修复了一些较小的构建故障后,我的项目可以正确编译,但是链接失败并出现以下错误:

After fixing a few minor build failures, my project compiles correctly, but linking fails with the following error:

g ++-4.8:错误:无法识别的命令行选项"-stdlib = libc ++" LLVM支持-stdlib =标志,但GCC不支持-stdlib =标志,因此会出错.

g++-4.8: error: unrecognized command line option ‘-stdlib=libc++’ The -stdlib= flag is supported by LLVM, but not GCC, hence the error.

在构建设置"中,用户定义"标题下有一个CLANG_CXX_LIBRARY标志.当我更改此标志的值时,错误将更改以反映当前值.但是,我无法从项目中完全删除此标志.

In Build Settings, there is a CLANG_CXX_LIBRARY flag under the User-Defined heading. When I change the value of this flag, the error changes to reflect the current value. However, I cannot remove this flag from the project entirely.

有没有一种方法可以阻止Xcode发出-stdlib =标志?

Is there a way to stop Xcode from emitting the -stdlib= flag?

推荐答案

在Xcode 6.1.1中,您可以在项目设置中删除CLANG_CXX_LIBRARY标志,但不能在目标设置中删除.要从目标更改为项目,请在按钮上分别标记基本"和全部".

In Xcode 6.1.1, you can delete the CLANG_CXX_LIBRARY flag in the project settings but not in the target settings. To change from target to project, there is a button just above the buttons labelled "Basic" and "All".

这篇关于如何在Xcode中删除CLANG_CXX_LIBRARY行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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