2012-05-12 4 views
1

埋め込みボードのフォノンとフォノンバックエンドを使ってQtをコンパイルしています。 私が入力します。Qtライブラリを設定する4.8.1クロスコンパイル時にエラーが発生する

./configure -embedded arm -xplatform qws/linux-arm-g++ -qt-mouse-tslib -L/home/user/ev-sdk/rootfs/arm-a8-fs/usr/lib -L/home/user/Desktop/qt-everywhere-opensource-src-4.8.1/lib -I/home/user/ev-sdk/rootfs/arm-a8-fs/usr/include -I/home/user/ev-sdk/rootfs/arm-a8-fs/usr/include/freetype2/freetype/config -prefix /opt/qt_eng -little-endian -no-gif -no-libtiff -no-libmng -no-openssl -no-opengl -no-mmx -no-3dnow -no-sse -no-sse2 -no-largefile -no-sm -svg -v -no-feature-cursor -fast -opensource -release -no-multimedia -no-cups -no-nis -no-exceptions -nomake examples -nomake demos -no-sql-sqlite -no-g++-exceptions -phonon -phonon-backend -DQT_NO_QWS_CURSOR -DQT_THREAD_SUPPORT 

qmake.confと/home/user/Desktop/qt-everywhere-opensource-src-4.8.1/mkspecs/qws/linux-arm-g++に:

# 
# qmake configuration for building with arm-linux-g++ # 


include(../../common/gcc-base.conf) 
include(../../common/gcc-base-unix.conf) 
include(../../common/g++.conf) 
include(../../common/linux.conf) 
include(../../common/qws.conf) 

QMAKE_CFLAGS_RELEASE  = -O3 -march=armv7-a -mtune=cortex-a8 
-mfpu=neon -mfloat-abi=softfp 

DEFINES += 

# modifications to g++.conf 
QMAKE_CC    = sb2 -t imx53 gcc 
QMAKE_CXX    = sb2 -t imx53 g++ 
QMAKE_LINK    = sb2 -t imx53 g++ 
QMAKE_LINK_SHLIB  = sb2 -t imx53 g++ 

# modifications to linux.conf 
QMAKE_AR    = sb2 -t imx53 ar cqs 
QMAKE_OBJCOPY   = sb2 -t imx53 objcopy 
QMAKE_STRIP    = sb2 -t imx53 strip 

load(qt_config) 

オプションから-phonon -phonon-backendを削除すると、コンパイルは成功します。私はこのエラーを持っている-phonon -phonon-backend を置く場合 は:

. 
. 
. 
D-Bus auto-detection...() 
Project WARNING: Your mkspec is including 'common/g++.conf', but the mkspecs have been refactored 
To fix this include 'common/gcc-base-.conf and 'common/g++-.conf' instead 
sb2 -t imx53 g++ -c -pipe -pipe -pipe -pipe -pipe -pipe -O2 -O2 -O2 -O2 -O2 -O2 -Wall -W -Wall -W -Wall -W -Wall -W -Wall -W -Wall -W -I../../../mkspecs/qws/linux-arm-g++ -I. -I/home/user/ev-sdk/rootfs/arm-a8-fs/usr/include -I/home/user/ev-sdk/rootfs/arm-a8-fs/usr/include/freetype2/freetype/config -I/usr/lib/glib-2.0/include -I/usr/include/glib-2.0 -o dbus.o dbus.cpp 
dbus.cpp:43:23: error: dbus/dbus.h: No such file or directory 
dbus.cpp:46:2: error: #error Needs at least dbus version 1 
dbus.cpp: In function 'int main(int, char**)': 
dbus.cpp:51: error: 'dbus_shutdown' was not declared in this scope 
make: *** [dbus.o] Error 1 
D-Bus disabled. 
Glib auto-detection...() 
Project WARNING: Your mkspec is including 'common/g++.conf', but the mkspecs have been refactored 
To fix this include 'common/gcc-base-.conf and 'common/g++-.conf' instead 
sb2 -t imx53 g++ -c -pipe -pipe -pipe -pipe -pipe -pipe -O2 -O2 -O2 -O2 -O2 -O2 -Wall -W -Wall -W -Wall -W -Wall -W -Wall -W -Wall -W -I../../../mkspecs/qws/linux-arm-g++ -I. -I/home/user/ev-sdk/rootfs/arm-a8-fs/usr/include -I/home/user/ev-sdk/rootfs/arm-a8-fs/usr/include/freetype2/freetype/config -I/usr/lib/glib-2.0/include -I/usr/include/glib-2.0 -o glib.o glib.cpp 
glib.cpp: In function 'int main(int, char**)': 
glib.cpp:55: warning: 'pollfd' is used uninitialized in this function 
sb2 -t imx53 g++ -Wl,-O1 -o glib glib.o  -L/home/user/ev-sdk/rootfs/arm-a8-fs/usr/lib -L/home/user/Desktop/qt-everywhere-opensource-src-4.8.1/lib 
*glib.o: In function `main': 
glib.cpp:(.text+0x10): undefined reference to `g_thread_init' 
glib.cpp:(.text+0x14): undefined reference to `g_main_context_default' 
glib.cpp:(.text+0x20): undefined reference to `g_source_new' 
glib.cpp:(.text+0x28): undefined reference to `g_source_add_poll' 
glib.cpp:(.text+0x38): undefined reference to `g_threads_got_initialized' 
collect2: ld returned 1 exit status 
make: *** [glib] Error 1* 
Glib disabled. 
Phonon support cannot be enabled due to functionality tests! 
Turn on verbose messaging (-v) to ./configure to see the final report. 
If you believe this message is in error you may use the continue 
switch (-continue) to ./configure to continue. 

私はエラーを与える理由を理解するために、最後の2日間失いました。

誰かが私を助けることができますか?

+0

あなたはすでにこれらの未定義の参照を調査していないですか?あなたのsysrootにlibgthread-2.0がありますか? –

答えて

1

のDebian/Linuxが使用することができます。

$ sudo apt-get install libgstreamer0.10-dev libgstreamer-plugins-base0.10-dev 

コマンドは、実行前に実行することができます./configure

0
QMAKE_LIBDIR   += -L$${ROOTFS_DIR}/usr/lib 
QMAKE_CFLAGS   += -I$${ROOTFS_DIR}/usr/include/glib-2.0 
QMAKE_CFLAGS   += -I$${ROOTFS_DIR}/usr/lib/glib-2.0/include 
QMAKE_LIBS    += -lgthread-2.0 -lglib-2.0 -v 
関連する問題