沉默“目录是空的”。警告 [英] Silence "table of contents is empty" warning
问题描述
在链接仅包含类别的库时,是否可以将目录为空警告静音?
Is it possible to silence the "table of contents is empty" warning when linking a library that contains only categories?
警告:
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool:
警告库:{some library} for architecture:{some
architecture}目录为空(库中没有对象文件成员
定义全局符号)
warning: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool: warning for library: {some library} for architecture: {some architecture} the table of contents is empty (no object file members in the library define global symbols)
我知道在任何实现文件中添加一个空类将删除警告,但我不想添加一个人工类。
I'm aware that adding an empty class in any implementation file would remove the warning, but I would prefer not to add an artificial class.
推荐答案
libtool接受-no_warning_for_no_symbols选项。
libtool accepts -no_warning_for_no_symbols option.
这篇关于沉默“目录是空的”。警告的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!