[求助]交叉编译wxwidgets-2.9.4遇到了问题
Posted: Tue Mar 12, 2013 5:43 am
这几天试了一下交叉编译wxWidgets-2.9.4,这是一个开发版的wxWidgets,我编译的是X11平台上的。编译的过程如下
1 编译zlib ncurses tinyx
这几个是我自己以前就编译好的,直接拿过来就可以了
2 编译 freetype libxml glib cairo libpng pixman libXft fontconfig pango pangox-compat
3 后面再编译的wxWidgets-2.9.4
这个过程虽然出现过一些问题,但是后面都编译通过了。
于是开始编译它后面的例子,编译的是sample下的minimal这个文件夹,这时候在链接的时候就出了问题了,问题挺多的:
dcclient.cpp:(.text+0x5bc4): undefined reference to `pango_x_render'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcFontSetDestroy'
/build/lib/libSM.so: undefined reference to `_IceErrorBadMinor'
/build/lib/libSM.so: undefined reference to `_IceWrite'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcFreeTypeCharIndex'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternAddString'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternGetCharSet'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternAddMatrix'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcObjectSetCreate'
/build/lib/libSM.so: undefined reference to `IceRegisterForProtocolReply'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternGetBool'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Load_Glyph'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcDefaultSubstitute'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Get_Kerning'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcCharSetNextPage'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternGetInteger'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Set_Transform'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcCharSetHasChar'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_type_double'
/build/lib/libSM.so: undefined reference to `_IceReadSkip'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Get_First_Char'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_type_pointer'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_type_sint64'
/build/lib/libSM.so: undefined reference to `IceProcessMessages'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternGetString'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcFontSort'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternCreate'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Init_FreeType'
/build/lib/libSM.so: undefined reference to `IceLastSentSequenceNumber'
/build/lib/libSM.so: undefined reference to `IceAllocScratch'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_type_void'
/build/lib/libSM.so: undefined reference to `IceFlush'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcFontList'
/build/lib/libSM.so: undefined reference to `IceCloseConnection'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternReference'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcObjectSetAdd'
/build/lib/libSM.so: undefined reference to `_IceErrorBadValue'
/build/lib/libSM.so: undefined reference to `_IceTransGetPeerNetworkId'
/build/lib/libSM.so: undefined reference to `IceProtocolShutdown'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternEqual'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Get_Next_Char'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_type_sint32'
/build/lib/libSM.so: undefined reference to `IceSetShutdownNegotiation'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcConfigSubstitute'
/build/lib/libSM.so: undefined reference to `_IceRead'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternBuild'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_type_uint64'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_call'
/build/lib/libSM.so: undefined reference to `IceProtocolSetup'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcCharSetFirstPage'
/build/lib/libSM.so: undefined reference to `IceOpenConnection'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternAddDouble'
/build/lib/libSM.so: undefined reference to `_IceErrorBadLength'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcObjectSetBuild'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Set_Charmap'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Get_Sfnt_Table'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcObjectSetDestroy'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternGet'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternDestroy'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcFontRenderPrepare'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternDuplicate'
/build/lib/libSM.so: undefined reference to `_IcePaMagicCookie1Proc'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Vector_Transform'
/build/lib/libSM.so: undefined reference to `_IcePoMagicCookie1Proc'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcFontSetSortDestroy'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcFontMatch'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternGetMatrix'
/build/lib/libSM.so: undefined reference to `_IceErrorBadState'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Done_FreeType'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_type_uint32'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Set_Char_Size'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_prep_cif'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_New_Face'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Render_Glyph'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternGetDouble'
/build/lib/libSM.so: undefined reference to `IceRegisterForProtocolSetup'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Done_Face'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternHash'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_type_float'
collect2: ld returned 1 exit status
我觉得应该是编译哪个库的时候出了问题,少了东西或者版本什么的有问题,但是都没报错。
后面又试了静态编译,编译的时候也没出问题,但是在编译它的例子的时候却出现了一些库找不到的问题,
如下:
/arm-2012.03/bin/../lib/gcc/arm-none-linux-gnueabi/4.6.3/../../../../arm-none-linux-gnueabi/bin/ld: warning: libgthread-2.0.so.0, needed by /build/lib/libgobject-2.0.so, not found (try using -rpath or -rpath-link)
/arm-2012.03/bin/../lib/gcc/arm-none-linux-gnueabi/4.6.3/../../../../arm-none-linux-gnueabi/bin/ld: warning: libffi.so.6, needed by /build/lib/libgobject-2.0.so, not found (try using -rpath or -rpath-link)
/arm-2012.03/bin/../lib/gcc/arm-none-linux-gnueabi/4.6.3/../../../../arm-none-linux-gnueabi/bin/ld: warning: libz.so.1, needed by /build/lib/libpangoft2-1.0.so, not found (try using -rpath or -rpath-link)
/arm-2012.03/bin/../lib/gcc/arm-none-linux-gnueabi/4.6.3/../../../../arm-none-linux-gnueabi/bin/ld: warning: libexpat.so.0, needed by /build/lib/libpangoft2-1.0.so, not found (try using -rpath or -rpath-link)
/arm-2012.03/bin/../lib/gcc/arm-none-linux-gnueabi/4.6.3/../../../../arm-none-linux-gnueabi/bin/ld: warning: libXrender.so.1, needed by /build/lib/libpangoxft-1.0.so, not found (try using -rpath or -rpath-link)
/arm-2012.03/bin/../lib/gcc/arm-none-linux-gnueabi/4.6.3/../../../../arm-none-linux-gnueabi/bin/ld: warning: libICE.so.6, needed by /build/lib/libSM.so, not found (try using -rpath or -rpath-link)
/arm-2012.03/bin/../lib/gcc/arm-none-linux-gnueabi/4.6.3/../../../../arm-none-linux-gnueabi/bin/ld: minimal: hidden symbol `inflateInit2_' in /home/mine/wxx11/wxWidgets-2.9.4/lib/libwxzlib-2.9-arm-linux.a(wxzlib_inflate.o) is referenced by DSO
/arm-2012.03/bin/../lib/gcc/arm-none-linux-gnueabi/4.6.3/../../../../arm-none-linux-gnueabi/bin/ld: final link failed: Bad value
collect2: ld returned 1 exit status
想问下各位移植达人,这些问题怎么解决呢,帮帮我吧!
1 编译zlib ncurses tinyx
这几个是我自己以前就编译好的,直接拿过来就可以了
2 编译 freetype libxml glib cairo libpng pixman libXft fontconfig pango pangox-compat
3 后面再编译的wxWidgets-2.9.4
这个过程虽然出现过一些问题,但是后面都编译通过了。
于是开始编译它后面的例子,编译的是sample下的minimal这个文件夹,这时候在链接的时候就出了问题了,问题挺多的:
dcclient.cpp:(.text+0x5bc4): undefined reference to `pango_x_render'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcFontSetDestroy'
/build/lib/libSM.so: undefined reference to `_IceErrorBadMinor'
/build/lib/libSM.so: undefined reference to `_IceWrite'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcFreeTypeCharIndex'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternAddString'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternGetCharSet'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternAddMatrix'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcObjectSetCreate'
/build/lib/libSM.so: undefined reference to `IceRegisterForProtocolReply'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternGetBool'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Load_Glyph'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcDefaultSubstitute'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Get_Kerning'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcCharSetNextPage'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternGetInteger'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Set_Transform'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcCharSetHasChar'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_type_double'
/build/lib/libSM.so: undefined reference to `_IceReadSkip'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Get_First_Char'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_type_pointer'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_type_sint64'
/build/lib/libSM.so: undefined reference to `IceProcessMessages'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternGetString'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcFontSort'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternCreate'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Init_FreeType'
/build/lib/libSM.so: undefined reference to `IceLastSentSequenceNumber'
/build/lib/libSM.so: undefined reference to `IceAllocScratch'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_type_void'
/build/lib/libSM.so: undefined reference to `IceFlush'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcFontList'
/build/lib/libSM.so: undefined reference to `IceCloseConnection'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternReference'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcObjectSetAdd'
/build/lib/libSM.so: undefined reference to `_IceErrorBadValue'
/build/lib/libSM.so: undefined reference to `_IceTransGetPeerNetworkId'
/build/lib/libSM.so: undefined reference to `IceProtocolShutdown'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternEqual'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Get_Next_Char'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_type_sint32'
/build/lib/libSM.so: undefined reference to `IceSetShutdownNegotiation'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcConfigSubstitute'
/build/lib/libSM.so: undefined reference to `_IceRead'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternBuild'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_type_uint64'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_call'
/build/lib/libSM.so: undefined reference to `IceProtocolSetup'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcCharSetFirstPage'
/build/lib/libSM.so: undefined reference to `IceOpenConnection'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternAddDouble'
/build/lib/libSM.so: undefined reference to `_IceErrorBadLength'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcObjectSetBuild'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Set_Charmap'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Get_Sfnt_Table'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcObjectSetDestroy'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternGet'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternDestroy'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcFontRenderPrepare'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternDuplicate'
/build/lib/libSM.so: undefined reference to `_IcePaMagicCookie1Proc'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Vector_Transform'
/build/lib/libSM.so: undefined reference to `_IcePoMagicCookie1Proc'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcFontSetSortDestroy'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcFontMatch'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternGetMatrix'
/build/lib/libSM.so: undefined reference to `_IceErrorBadState'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Done_FreeType'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_type_uint32'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Set_Char_Size'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_prep_cif'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_New_Face'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Render_Glyph'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternGetDouble'
/build/lib/libSM.so: undefined reference to `IceRegisterForProtocolSetup'
/build/lib/libpangoft2-1.0.so: undefined reference to `FT_Done_Face'
/build/lib/libpangoft2-1.0.so: undefined reference to `FcPatternHash'
/build/lib/libgobject-2.0.so: undefined reference to `ffi_type_float'
collect2: ld returned 1 exit status
我觉得应该是编译哪个库的时候出了问题,少了东西或者版本什么的有问题,但是都没报错。
后面又试了静态编译,编译的时候也没出问题,但是在编译它的例子的时候却出现了一些库找不到的问题,
如下:
/arm-2012.03/bin/../lib/gcc/arm-none-linux-gnueabi/4.6.3/../../../../arm-none-linux-gnueabi/bin/ld: warning: libgthread-2.0.so.0, needed by /build/lib/libgobject-2.0.so, not found (try using -rpath or -rpath-link)
/arm-2012.03/bin/../lib/gcc/arm-none-linux-gnueabi/4.6.3/../../../../arm-none-linux-gnueabi/bin/ld: warning: libffi.so.6, needed by /build/lib/libgobject-2.0.so, not found (try using -rpath or -rpath-link)
/arm-2012.03/bin/../lib/gcc/arm-none-linux-gnueabi/4.6.3/../../../../arm-none-linux-gnueabi/bin/ld: warning: libz.so.1, needed by /build/lib/libpangoft2-1.0.so, not found (try using -rpath or -rpath-link)
/arm-2012.03/bin/../lib/gcc/arm-none-linux-gnueabi/4.6.3/../../../../arm-none-linux-gnueabi/bin/ld: warning: libexpat.so.0, needed by /build/lib/libpangoft2-1.0.so, not found (try using -rpath or -rpath-link)
/arm-2012.03/bin/../lib/gcc/arm-none-linux-gnueabi/4.6.3/../../../../arm-none-linux-gnueabi/bin/ld: warning: libXrender.so.1, needed by /build/lib/libpangoxft-1.0.so, not found (try using -rpath or -rpath-link)
/arm-2012.03/bin/../lib/gcc/arm-none-linux-gnueabi/4.6.3/../../../../arm-none-linux-gnueabi/bin/ld: warning: libICE.so.6, needed by /build/lib/libSM.so, not found (try using -rpath or -rpath-link)
/arm-2012.03/bin/../lib/gcc/arm-none-linux-gnueabi/4.6.3/../../../../arm-none-linux-gnueabi/bin/ld: minimal: hidden symbol `inflateInit2_' in /home/mine/wxx11/wxWidgets-2.9.4/lib/libwxzlib-2.9-arm-linux.a(wxzlib_inflate.o) is referenced by DSO
/arm-2012.03/bin/../lib/gcc/arm-none-linux-gnueabi/4.6.3/../../../../arm-none-linux-gnueabi/bin/ld: final link failed: Bad value
collect2: ld returned 1 exit status
想问下各位移植达人,这些问题怎么解决呢,帮帮我吧!