• 13932阅读
  • 2回复

[提问]QT5+VS2013静态库使用时LINK错误unresolved external symbol _hb_buffer_create [复制链接]

上一主题 下一主题
离线yanzhuliang
 

只看楼主 倒序阅读 楼主  发表于: 2015-01-05
最近用QT5+VS2013编译了qt静态库,使用的configure如下:
configure -confirm-license -opensource -platform win32-msvc2013 -debug-and-release -static -prefix "E:\Qt\5.4.0.vs2013.lib" -qt-sql-sqlite -qt-sql-odbc -plugin-sql-sqlite -plugin-sql-odbc -qt-zlib -qt-libpng -qt-libjpeg -opengl desktop -qt-freetype -no-qml-debug -no-angle -nomake tests -nomake examples -skip qtwebkit

然后创建了一个helloword,发现LINK出错(注意:你应该在编译前将OpenGL32.lib和GLu32.lib加入到工程配置),请大神帮忙看看:
    helloword源码 helloqt5.rar (8 K) 下载次数:1

    



详细错误信息如下:
1>------ Rebuild All started: Project: helloqt5, Configuration: Debug Win32 ------
1>  Moc'ing helloqt5.h...
1>  Uic'ing helloqt5.ui...
1>  Rcc'ing helloqt5.qrc...
1>RCC : warning : No resources in 'E:\visualstudio\helloqt5\helloqt5.qrc'.
1>  
1>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppBuild.targets(935,5): warning MSB8027: Two or more files with the name of moc_helloqt5.cpp will produce outputs to the same location. This can lead to an incorrect build result.  The files involved are GeneratedFiles\Debug\moc_helloqt5.cpp, GeneratedFiles\Release\moc_helloqt5.cpp.
1>  moc_helloqt5.cpp
1>  helloqt5.cpp
1>  main.cpp
1>  Generating Code...
1>  qrc_helloqt5.cpp
1>     Creating library E:\visualstudio\helloqt5\Win32\Debug\helloqt5.lib and object E:\visualstudio\helloqt5\Win32\Debug\helloqt5.exp
1>Qt5Guid.lib(qtextengine.obj) : error LNK2019: unresolved external symbol _hb_buffer_create referenced in function "private: int __thiscall QTextEngine::shapeTextWithHarfbuzzNG(struct QScriptItem const &,unsigned short const *,int,class QFontEngine *,class QVector<unsigned int> const &,bool)const " (?shapeTextWithHarfbuzzNG@QTextEngine@@ABEHABUQScriptItem@@PBGHPAVQFontEngine@@ABV?$QVector@I@@_N@Z)
1>Qt5Guid.lib(qtextengine.obj) : error LNK2019: unresolved external symbol _hb_buffer_destroy referenced in function "private: int __thiscall QTextEngine::shapeTextWithHarfbuzzNG(struct QScriptItem const &,unsigned short const *,int,class QFontEngine *,class QVector<unsigned int> const &,bool)const " (?shapeTextWithHarfbuzzNG@QTextEngine@@ABEHABUQScriptItem@@PBGHPAVQFontEngine@@ABV?$QVector@I@@_N@Z)
1>Qt5Guid.lib(qtextengine.obj) : error LNK2019: unresolved external symbol _hb_buffer_set_unicode_funcs referenced in function "private: int __thiscall QTextEngine::shapeTextWithHarfbuzzNG(struct QScriptItem const &,unsigned short const *,int,class QFontEngine *,class QVector<unsigned int> const &,bool)const " (?shapeTextWithHarfbuzzNG@QTextEngine@@ABEHABUQScriptItem@@PBGHPAVQFontEngine@@ABV?$QVector@I@@_N@Z)
1>Qt5Guid.lib(qtextengine.obj) : error LNK2019: unresolved external symbol _hb_buffer_set_segment_properties referenced in function "private: int __thiscall QTextEngine::shapeTextWithHarfbuzzNG(struct QScriptItem const &,unsigned short const *,int,class QFontEngine *,class QVector<unsigned int> const &,bool)const " (?shapeTextWithHarfbuzzNG@QTextEngine@@ABEHABUQScriptItem@@PBGHPAVQFontEngine@@ABV?$QVector@I@@_N@Z)
1>Qt5Guid.lib(qtextengine.obj) : error LNK2019: unresolved external symbol _hb_buffer_guess_segment_properties referenced in function "private: int __thiscall QTextEngine::shapeTextWithHarfbuzzNG(struct QScriptItem const &,unsigned short const *,int,class QFontEngine *,class QVector<unsigned int> const &,bool)const " (?shapeTextWithHarfbuzzNG@QTextEngine@@ABEHABUQScriptItem@@PBGHPAVQFontEngine@@ABV?$QVector@I@@_N@Z)
1>Qt5Guid.lib(qtextengine.obj) : error LNK2019: unresolved external symbol _hb_buffer_set_flags referenced in function "private: int __thiscall QTextEngine::shapeTextWithHarfbuzzNG(struct QScriptItem const &,unsigned short const *,int,class QFontEngine *,class QVector<unsigned int> const &,bool)const " (?shapeTextWithHarfbuzzNG@QTextEngine@@ABEHABUQScriptItem@@PBGHPAVQFontEngine@@ABV?$QVector@I@@_N@Z)
1>Qt5Guid.lib(qtextengine.obj) : error LNK2019: unresolved external symbol _hb_buffer_clear_contents referenced in function "private: int __thiscall QTextEngine::shapeTextWithHarfbuzzNG(struct QScriptItem const &,unsigned short const *,int,class QFontEngine *,class QVector<unsigned int> const &,bool)const " (?shapeTextWithHarfbuzzNG@QTextEngine@@ABEHABUQScriptItem@@PBGHPAVQFontEngine@@ABV?$QVector@I@@_N@Z)
1>Qt5Guid.lib(qtextengine.obj) : error LNK2019: unresolved external symbol _hb_buffer_pre_allocate referenced in function "private: int __thiscall QTextEngine::shapeTextWithHarfbuzzNG(struct QScriptItem const &,unsigned short const *,int,class QFontEngine *,class QVector<unsigned int> const &,bool)const " (?shapeTextWithHarfbuzzNG@QTextEngine@@ABEHABUQScriptItem@@PBGHPAVQFontEngine@@ABV?$QVector@I@@_N@Z)
1>Qt5Guid.lib(qtextengine.obj) : error LNK2019: unresolved external symbol _hb_buffer_allocation_successful referenced in function "private: int __thiscall QTextEngine::shapeTextWithHarfbuzzNG(struct QScriptItem const &,unsigned short const *,int,class QFontEngine *,class QVector<unsigned int> const &,bool)const " (?shapeTextWithHarfbuzzNG@QTextEngine@@ABEHABUQScriptItem@@PBGHPAVQFontEngine@@ABV?$QVector@I@@_N@Z)
1>Qt5Guid.lib(qtextengine.obj) : error LNK2019: unresolved external symbol _hb_buffer_reverse referenced in function "private: int __thiscall QTextEngine::shapeTextWithHarfbuzzNG(struct QScriptItem const &,unsigned short const *,int,class QFontEngine *,class QVector<unsigned int> const &,bool)const " (?shapeTextWithHarfbuzzNG@QTextEngine@@ABEHABUQScriptItem@@PBGHPAVQFontEngine@@ABV?$QVector@I@@_N@Z)
1>Qt5Guid.lib(qtextengine.obj) : error LNK2019: unresolved external symbol _hb_buffer_add_utf16 referenced in function "private: int __thiscall QTextEngine::shapeTextWithHarfbuzzNG(struct QScriptItem const &,unsigned short const *,int,class QFontEngine *,class QVector<unsigned int> const &,bool)const " (?shapeTextWithHarfbuzzNG@QTextEngine@@ABEHABUQScriptItem@@PBGHPAVQFontEngine@@ABV?$QVector@I@@_N@Z)
1>Qt5Guid.lib(qtextengine.obj) : error LNK2019: unresolved external symbol _hb_buffer_get_length referenced in function "private: int __thiscall QTextEngine::shapeTextWithHarfbuzzNG(struct QScriptItem const &,unsigned short const *,int,class QFontEngine *,class QVector<unsigned int> const &,bool)const " (?shapeTextWithHarfbuzzNG@QTextEngine@@ABEHABUQScriptItem@@PBGHPAVQFontEngine@@ABV?$QVector@I@@_N@Z)
1>Qt5Guid.lib(qtextengine.obj) : error LNK2019: unresolved external symbol _hb_buffer_get_glyph_infos referenced in function "private: int __thiscall QTextEngine::shapeTextWithHarfbuzzNG(struct QScriptItem const &,unsigned short const *,int,class QFontEngine *,class QVector<unsigned int> const &,bool)const " (?shapeTextWithHarfbuzzNG@QTextEngine@@ABEHABUQScriptItem@@PBGHPAVQFontEngine@@ABV?$QVector@I@@_N@Z)
1>Qt5Guid.lib(qtextengine.obj) : error LNK2019: unresolved external symbol _hb_buffer_get_glyph_positions referenced in function "private: int __thiscall QTextEngine::shapeTextWithHarfbuzzNG(struct QScriptItem const &,unsigned short const *,int,class QFontEngine *,class QVector<unsigned int> const &,bool)const " (?shapeTextWithHarfbuzzNG@QTextEngine@@ABEHABUQScriptItem@@PBGHPAVQFontEngine@@ABV?$QVector@I@@_N@Z)
1>Qt5Guid.lib(qtextengine.obj) : error LNK2019: unresolved external symbol _hb_shape_full referenced in function "private: int __thiscall QTextEngine::shapeTextWithHarfbuzzNG(struct QScriptItem const &,unsigned short const *,int,class QFontEngine *,class QVector<unsigned int> const &,bool)const " (?shapeTextWithHarfbuzzNG@QTextEngine@@ABEHABUQScriptItem@@PBGHPAVQFontEngine@@ABV?$QVector@I@@_N@Z)
1>Qt5Guid.lib(qfontengine.obj) : error LNK2019: unresolved external symbol _hb_ot_tags_from_script referenced in function "public: bool __thiscall QFontEngine::supportsScript(enum QChar::Script)const " (?supportsScript@QFontEngine@@QBE_NW4Script@QChar@@@Z)
1>Qt5Guid.lib(qfontengine.obj) : error LNK2019: unresolved external symbol _hb_ot_layout_table_find_script referenced in function "public: bool __thiscall QFontEngine::supportsScript(enum QChar::Script)const " (?supportsScript@QFontEngine@@QBE_NW4Script@QChar@@@Z)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_blob_create referenced in function "struct hb_blob_t * __cdecl _hb_qt_reference_table(struct hb_face_t *,unsigned int,void *)" (?_hb_qt_reference_table@@YAPAUhb_blob_t@@PAUhb_face_t@@IPAX@Z)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_blob_get_empty referenced in function "struct hb_blob_t * __cdecl _hb_qt_reference_table(struct hb_face_t *,unsigned int,void *)" (?_hb_qt_reference_table@@YAPAUhb_blob_t@@PAUhb_face_t@@IPAX@Z)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_unicode_funcs_create referenced in function "public: __thiscall _hb_unicode_funcs_t::_hb_unicode_funcs_t(void)" (??0_hb_unicode_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_unicode_funcs_destroy referenced in function "public: __thiscall _hb_unicode_funcs_t::~_hb_unicode_funcs_t(void)" (??1_hb_unicode_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_unicode_funcs_set_combining_class_func referenced in function "public: __thiscall _hb_unicode_funcs_t::_hb_unicode_funcs_t(void)" (??0_hb_unicode_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_unicode_funcs_set_eastasian_width_func referenced in function "public: __thiscall _hb_unicode_funcs_t::_hb_unicode_funcs_t(void)" (??0_hb_unicode_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_unicode_funcs_set_general_category_func referenced in function "public: __thiscall _hb_unicode_funcs_t::_hb_unicode_funcs_t(void)" (??0_hb_unicode_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_unicode_funcs_set_mirroring_func referenced in function "public: __thiscall _hb_unicode_funcs_t::_hb_unicode_funcs_t(void)" (??0_hb_unicode_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_unicode_funcs_set_script_func referenced in function "public: __thiscall _hb_unicode_funcs_t::_hb_unicode_funcs_t(void)" (??0_hb_unicode_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_unicode_funcs_set_compose_func referenced in function "public: __thiscall _hb_unicode_funcs_t::_hb_unicode_funcs_t(void)" (??0_hb_unicode_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_unicode_funcs_set_decompose_func referenced in function "public: __thiscall _hb_unicode_funcs_t::_hb_unicode_funcs_t(void)" (??0_hb_unicode_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_unicode_funcs_set_decompose_compatibility_func referenced in function "public: __thiscall _hb_unicode_funcs_t::_hb_unicode_funcs_t(void)" (??0_hb_unicode_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_face_create_for_tables referenced in function "struct hb_face_t * __cdecl _hb_qt_face_create(class QFontEngine *)" (?_hb_qt_face_create@@YAPAUhb_face_t@@PAVQFontEngine@@@Z)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_face_destroy referenced in function "struct hb_face_t * __cdecl _hb_qt_face_create(class QFontEngine *)" (?_hb_qt_face_create@@YAPAUhb_face_t@@PAVQFontEngine@@@Z)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_face_is_immutable referenced in function "struct hb_face_t * __cdecl _hb_qt_face_create(class QFontEngine *)" (?_hb_qt_face_create@@YAPAUhb_face_t@@PAVQFontEngine@@@Z)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_face_set_index referenced in function "struct hb_face_t * __cdecl _hb_qt_face_create(class QFontEngine *)" (?_hb_qt_face_create@@YAPAUhb_face_t@@PAVQFontEngine@@@Z)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_face_set_upem referenced in function "struct hb_face_t * __cdecl _hb_qt_face_create(class QFontEngine *)" (?_hb_qt_face_create@@YAPAUhb_face_t@@PAVQFontEngine@@@Z)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_funcs_create referenced in function "public: __thiscall _hb_qt_font_funcs_t::_hb_qt_font_funcs_t(void)" (??0_hb_qt_font_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_funcs_destroy referenced in function "public: __thiscall _hb_qt_font_funcs_t::~_hb_qt_font_funcs_t(void)" (??1_hb_qt_font_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_funcs_set_glyph_func referenced in function "public: __thiscall _hb_qt_font_funcs_t::_hb_qt_font_funcs_t(void)" (??0_hb_qt_font_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_funcs_set_glyph_h_advance_func referenced in function "public: __thiscall _hb_qt_font_funcs_t::_hb_qt_font_funcs_t(void)" (??0_hb_qt_font_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_funcs_set_glyph_v_advance_func referenced in function "public: __thiscall _hb_qt_font_funcs_t::_hb_qt_font_funcs_t(void)" (??0_hb_qt_font_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_funcs_set_glyph_h_origin_func referenced in function "public: __thiscall _hb_qt_font_funcs_t::_hb_qt_font_funcs_t(void)" (??0_hb_qt_font_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_funcs_set_glyph_v_origin_func referenced in function "public: __thiscall _hb_qt_font_funcs_t::_hb_qt_font_funcs_t(void)" (??0_hb_qt_font_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_funcs_set_glyph_h_kerning_func referenced in function "public: __thiscall _hb_qt_font_funcs_t::_hb_qt_font_funcs_t(void)" (??0_hb_qt_font_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_funcs_set_glyph_v_kerning_func referenced in function "public: __thiscall _hb_qt_font_funcs_t::_hb_qt_font_funcs_t(void)" (??0_hb_qt_font_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_funcs_set_glyph_extents_func referenced in function "public: __thiscall _hb_qt_font_funcs_t::_hb_qt_font_funcs_t(void)" (??0_hb_qt_font_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_funcs_set_glyph_contour_point_func referenced in function "public: __thiscall _hb_qt_font_funcs_t::_hb_qt_font_funcs_t(void)" (??0_hb_qt_font_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_funcs_set_glyph_name_func referenced in function "public: __thiscall _hb_qt_font_funcs_t::_hb_qt_font_funcs_t(void)" (??0_hb_qt_font_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_funcs_set_glyph_from_name_func referenced in function "public: __thiscall _hb_qt_font_funcs_t::_hb_qt_font_funcs_t(void)" (??0_hb_qt_font_funcs_t@@QAE@XZ)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_create referenced in function "struct hb_font_t * __cdecl _hb_qt_font_create(class QFontEngine *)" (?_hb_qt_font_create@@YAPAUhb_font_t@@PAVQFontEngine@@@Z)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_destroy referenced in function "struct hb_font_t * __cdecl _hb_qt_font_create(class QFontEngine *)" (?_hb_qt_font_create@@YAPAUhb_font_t@@PAVQFontEngine@@@Z)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_set_user_data referenced in function "void __cdecl hb_qt_font_set_use_design_metrics(struct hb_font_t *,unsigned int)" (?hb_qt_font_set_use_design_metrics@@YAXPAUhb_font_t@@I@Z)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_get_user_data referenced in function "unsigned int __cdecl hb_qt_font_get_use_design_metrics(struct hb_font_t *)" (?hb_qt_font_get_use_design_metrics@@YAIPAUhb_font_t@@@Z)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_is_immutable referenced in function "struct hb_font_t * __cdecl _hb_qt_font_create(class QFontEngine *)" (?_hb_qt_font_create@@YAPAUhb_font_t@@PAVQFontEngine@@@Z)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_set_funcs referenced in function "struct hb_font_t * __cdecl _hb_qt_font_create(class QFontEngine *)" (?_hb_qt_font_create@@YAPAUhb_font_t@@PAVQFontEngine@@@Z)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_set_scale referenced in function "struct hb_font_t * __cdecl _hb_qt_font_create(class QFontEngine *)" (?_hb_qt_font_create@@YAPAUhb_font_t@@PAVQFontEngine@@@Z)
1>Qt5Guid.lib(qharfbuzzng.obj) : error LNK2019: unresolved external symbol _hb_font_set_ppem referenced in function "struct hb_font_t * __cdecl _hb_qt_font_create(class QFontEngine *)" (?_hb_qt_font_create@@YAPAUhb_font_t@@PAVQFontEngine@@@Z)
1>E:\visualstudio\helloqt5\Win32\Debug\\helloqt5.exe : fatal error LNK1120: 55 unresolved externals
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========
离线yanzhuliang

只看该作者 1楼 发表于: 2015-01-09
仍未解决,
离线supperbond

只看该作者 2楼 发表于: 2016-02-20
要手动加入链接库,debug版加入,qtharfbuzzngd.lib,release版加入qtharfbuzzng.lib
快速回复
限100 字节
 
上一个 下一个