ld: warning: -no_pie ignored for arm64
Undefined symbols for architecture arm64:
“_iconv_open”, referenced from:
cocos2d::FontAtlas::conversionU16TOGB2312(std::__1::basic_string<char16_t, std::__1::char_traits<char16_t>, std::__1::allocator<char16_t> > const&, std::__1::unordered_map<unsigned short, unsigned short, std::__1::hash, std::__1::equal_to, std::__1::allocator<std::__1::pair<unsigned short const, unsigned short> > >&) in libcocos2d iOS.a(CCFontAtlas.o)
“_iconv”, referenced from:
cocos2d::FontAtlas::conversionU16TOGB2312(std::__1::basic_string<char16_t, std::__1::char_traits<char16_t>, std::__1::allocator<char16_t> > const&, std::__1::unordered_map<unsigned short, unsigned short, std::__1::hash, std::__1::equal_to, std::__1::allocator<std::__1::pair<unsigned short const, unsigned short> > >&) in libcocos2d iOS.a(CCFontAtlas.o)
“_CTFramesetterCreateWithAttributedString”, referenced from:
_calculateShrinkedSizeForString(NSAttributedString**, objc_object*, CGSize, bool, int&) in libcocos2d iOS.a(CCDevice-ios.o)
“_iconv_close”, referenced from:
cocos2d::FontAtlas::~FontAtlas() in libcocos2d iOS.a(CCFontAtlas.o)
“_CTFramesetterSuggestFrameSizeWithConstraints”, referenced from:
_calculateShrinkedSizeForString(NSAttributedString**, objc_object*, CGSize, bool, int&) in libcocos2d iOS.a(CCDevice-ios.o)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
报问题应该提供详细的信息,包括引擎版本,怎么操作的,运行环境等。
cocos2d-x-3.14.1
Xcode 8.3.2 SDK 10.3
macOS 10.12.5
将以前cocos2d-x-3.4的项目中的库直接替换成cocos2d-x-3.14.1 clean 再 build 会报以上错误
不能直接替换吧。从错误来看像是缺少了iconv的库。