如何摆脱OSX10.10 SDK中的module.map警告? [英] How do I get rid of module.map warnings in the OSX10.10 SDK?
本文介绍了如何摆脱OSX10.10 SDK中的module.map警告?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
自从更新Xcode到版本6.3,我在编译C ++代码时收到以下警告:
Since updating Xcode to version 6.3, I have been getting the following warnings when compiling C++ code:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/module.map:1:25: warning: unknown attribute 'extern_c' [-Wignored-attributes]
module Darwin [system] [extern_c] {
^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/module.map:1561:21: warning: unknown attribute 'extern_c' [-Wignored-attributes]
module os [system] [extern_c] {
^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/module.map:1577:26: warning: unknown attribute 'extern_c' [-Wignored-attributes]
module libkern [system] [extern_c] {
^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/module.map:1602:23: warning: unknown attribute 'extern_c' [-Wignored-attributes]
module ldap [system] [extern_c] {
^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/module.map:1635:23: warning: unknown attribute 'extern_c' [-Wignored-attributes]
module krb5 [system] [extern_c] {
^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/module.map:1662:22: warning: unknown attribute 'extern_c' [-Wignored-attributes]
module XPC [system] [extern_c] {
^
有没有人知道如何解决这个问题,除了忽略-Wignored-attributes?
Does anyone have any idea how to fix this besides ignoring -Wignored-attributes?
推荐答案
原来我使用的是一个旧版本的clang与Xcode的SDK。使用默认的clang删除警告。
Turns out I was using an old version of clang with the SDK of Xcode. Using the default clang gets rid of the warnings.
这篇关于如何摆脱OSX10.10 SDK中的module.map警告?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文