qt4.8.6,opengl example,but Segmentation fault

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

qt4.8.6,opengl example,but Segmentation fault

2,761件の閲覧回数
longzimggg
Contributor II

I run example/opengl/hellogl_es2 that comes with qt on imx6, but it keeps reporting segmentation errors.  And when I run other non-opengl examples, they can run normally.

I cross-compiled on Linux. The version of qt is 4.8.6. Here are the compilation options:

 

 

./configure -prefix /home/mj/work/qt4.8.6/qt-everywhere-opensource-release-4.8.6 -opensource -confirm-license -release -shared -embedded arm -xplatform qws/linux-armv7-g++ -exceptions -depths all -fast -optimized-qmake -pch -qt-sql-sqlite -qt-libjpeg -qt-zlib -qt-libpng -qt-freetype -host-little-endian -little-endian -no-qt3support -no-libtiff -no-libmng -no-mmx -no-sse -no-sse2 -no-3dnow -no-openssl -no-webkit -no-qvfb -no-phonon -no-nis -no-cups -no-glib -no-xcursor -no-xfixes -no-xrandr -no-xrender -no-separate-debug-info -make examples -nomake tools -nomake docs -nomake demos -qt-gfx-linuxfb -qt-gfx-transformed -qt-mouse-tslib -qt-mouse-linuxinput -qt-kbd-linuxinput -plugin-mouse-tslib -I$TSLIB_DIR/include -L$TSLIB_DIR/lib -device-option CROSS_COMPILE=/home/chenyao/toolchain/toolchain_arm_poky_mini/bin/arm-poky-linux-gnueabi- -qtlibinfix E -opengl es2

 

 

Here is my debugging command:

 

 

root@imx6qsabresd:zbd
(zdb) file /tnetrol_media/qtfs/qt-everywhere-opensource-release-4.8.6/examples/opengl/hellogl_es2/hellogl_es2
(zdb) r -qws
Process /tnetrol_media/qtfs/qt-everywhere-opensource-release-4.8.6/examples/opengl/hellogl_es2/hellogl_es2 created; pid = 24220
Newly created process id 24220
[New Thread 24220]
0x76f8ed40 in ?? ()
(zdb) c
Continuing.
(zdb)
[New Thread 24232]
*thread : thread 24232 create!
(zdb)
Program received signal SIGSEGV, Segmentation fault.
0x75b3890c in gcoOS_DeinitLocalDisplayInfo (Display=0x0, localDisplay=localDisplay@entry=0x17a760)
at ../user/gc_hal_user_wayland.c:2310
2310 ../user/gc_hal_user_wayland.c: No such file or directory.
(zdb) *thread : thread 24232 exit!
(zdb) bt
#0 0x75b3890c in gcoOS_DeinitLocalDisplayInfo (Display=0x0, localDisplay=localDisplay@entry=0x17a760)
at ../user/gc_hal_user_wayland.c:2310
#1 0x75fe9588 in veglDeinitLocalDisplayInfo (Display=Display@entry=0x17a754) at gc_egl_platform.c:359
#2 0x75fe02f8 in veglTerminateDisplay (Display=0x17a754, Thread=0xa2c3c) at gc_egl_init.c:1329
#3 eglTerminate (Dpy=<optimized out>) at gc_egl_init.c:1497
#4 0x76c9d334 in QEglContext::~QEglContext() ()
from /tnetrol_media/qtfs/qt-everywhere-opensource-release-4.8.6/lib/libQtGuiE.so.4
#5 0x76e8ecb8 in QGLContext::chooseContext(QGLContext const*) ()
from /tnetrol_media/qtfs/qt-everywhere-opensource-release-4.8.6/lib/libQtOpenGLE.so.4
#6 0x76e4c124 in QGLContext::create(QGLContext const*) ()
from /tnetrol_media/qtfs/qt-everywhere-opensource-release-4.8.6/lib/libQtOpenGLE.so.4
#7 0x76e8e75c in QGLWidget::setContext(QGLContext*, QGLContext const*, bool) ()
from /tnetrol_media/qtfs/qt-everywhere-opensource-release-4.8.6/lib/libQtOpenGLE.so.4
#8 0x76e4bf48 in ?? () from /tnetrol_media/qtfs/qt-everywhere-opensource-release-4.8.6/lib/libQtOpenGLE.so.4
Cannot access memory at address 0x0
#9 0x76e4bf48 in ?? () from /tnetrol_media/qtfs/qt-everywhere-opensource-release-4.8.6/lib/libQtOpenGLE.so.4
Cannot access memory at address 0x0
Backtrace stopped: previous frame identical to this frame (corrupt stack?)

 

 

 

タグ(2)
0 件の賞賛
返信
6 返答(返信)

2,695件の閲覧回数
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hi

Are you using weston desktop?

Best Regards
Zhiming

0 件の賞賛
返信

2,683件の閲覧回数
longzimggg
Contributor II

微信图片_20241008140322.png

0 件の賞賛
返信

2,640件の閲覧回数
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hi

From the error log, it seems that there is some issue about GPU library relate to wayland in your rootfs, you should test the basical display function and gpu function witout qt.

Best Regards
Zhiming

0 件の賞賛
返信

2,627件の閲覧回数
longzimggg
Contributor II

Hi, the attachments is my demo about opengl es, but just the same fault. 

longzimggg_1-1728613497292.png

 

0 件の賞賛
返信

2,583件の閲覧回数
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hi

NXP provides basic test demo, please test GPU basic display function in /unit_tests if you are using image from NXP.

Best Regards
Zhiming

0 件の賞賛
返信

2,683件の閲覧回数
longzimggg
Contributor II

No, not weston. I am a beginner. When I start the screen, the screen shows that the configuration information is not set. Usually when I run other executable programs, the window will be displayed directly. I added some error messages debugged with gdb, please take a look.

0 件の賞賛
返信