Imagination PowerVR SDK Blog

Train program seg faults (remote X display only)

pvrvframe

#1

I’m a newbie to OpenGL.  I’m going to eventually be working with an MPC<SPAN =“highlight”>5121e board.  Until I get that board set up, I thought I’d get started with OpenGL using the Linux emulation SDK (SDK_OGLES-1.1_LINUX.tar.gz).   I compiled and ran training course programs 1-5 and all work fine.  Training course program #6 (Introducing PVR Tools), however, gets a segmentation fault.  Here’s the traceback from gdb:

 

Starting program: /home/brenda/linux_em/SDKPackage/TrainingCourse/06_IntroducingPVRTools/OGLES/Build/LinuxPC/ReleaseX11/OGLESIntroducingPVRTools
[Thread debugging using libthread_db enabled]
[New Thread 0xb793c8d0 (LWP 23674)]
PVRShell: EGL 1.3 initialized
Profile Chosen: MBXLITE

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0xb793c8d0 (LWP 23674)]
0xb7e3158b in glDrawElements ()
   from /home/brenda/linux_em/SDKPackage/Builds/OGLES/LinuxPC/Lib/libGLES_CM.so
(gdb) where
#0  0xb7e3158b in glDrawElements ()
   from /home/brenda/linux_em/SDKPackage/Builds/OGLES/LinuxPC/Lib/libGLES_CM.so
#1  0x080514aa in CPVRTPrint3D::Flush ()
#2  0x0804a8ad in OGLESIntroducingPVRTools::RenderScene ()
#3  0x0804caea in PVRShellInit::Run ()
#4  0x0804dd8c in main ()
(gdb)

 

Any thoughts appreciated.  Not sure if it matters but I tested by openGL/X window set up with glxgears and that looked good.

 

Thanks,
Brenda

 
kbmom10082009-04-14 20:56:26

#2

1.  Could You describe exactly the procedure that you have executed after unpacking the archive eg. command  you type to build this demo , shell variable you set (if any) before you compile and before you run demo and directory from which you are typing building command.

2. what is the full name of the archive of this SDK?.Â

3.  please  put training course nr 4 , following line:

glGetString(GL_RENDERER);

in console you should see identication of pc emulation which I would like to ask you to present here.

Looking forward to have an response from you


jacekc2009-04-09 17:34:48

#3
Thanks for the reply.  Here's the info you requested.  Sorry for the line wrapping.

 

1.  Procedures to build and execute training program that faults (SDKPackage unpacked at ~/linux_em):

 

a. set environment variables

>export LD_LIBRARY_PATH=/home/brenda/linux_em/SDKPackage/Builds/OGLES/LinuxPC/Lib
>export PLATFORM=LinuxPC

 

b. cd to Build/.../LinuxGeneric directory of component being built, in this case:

> cd ~/linux_em/SDKPackage/TrainingCourse/06_IntroducingPVRTools/OGLES/Build/LinuxGeneric$

 

c. build the executable:

> make Common=1
Makefile:24: warning: overriding commands for target `clean'
../../../../../Builds/OGLES/LinuxGeneric/make_demo.mak:119: warning: ignoring old commands for target `clean'
+t+ Making content.mak
make[1]: Entering directory `/home/brenda/linux_em/SDKPackage/TrainingCourse/06_IntroducingPVRTools/OGLES'
make[1]: `all' is up to date.
make[1]: Leaving directory `/home/brenda/linux_em/SDKPackage/TrainingCourse/06_IntroducingPVRTools/OGLES'
+c+ ../LinuxPC/ReleaseX11/Image.o
gcc -c -I/home/brenda/linux_em/SDKPackage/Tools/OGLES -I/home/brenda/linux_em/SDKPackage/Shell -I/home/brenda/linux_em/SDKPackage/Shell/API/KEGL -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/LinuxPC/Include -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/Include -I/home/brenda/linux_em/SDKPackage/Shell/OS/LinuxX11 -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/Include -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/LinuxPC/Include -I/usr/X11R6/include -I../../.. -m32 -DBUILD_OGLES -Wall -DRELEASE -O2 ../../Content/Image.cpp -o../LinuxPC/ReleaseX11/Image.o
+c+ OGLESIntroducingPVRTools ../LinuxPC/ReleaseX11/OGLESIntroducingPVRTools.o
gcc -c -I/home/brenda/linux_em/SDKPackage/Tools/OGLES -I/home/brenda/linux_em/SDKPackage/Shell -I/home/brenda/linux_em/SDKPackage/Shell/API/KEGL -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/LinuxPC/Include -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/Include -I/home/brenda/linux_em/SDKPackage/Shell/OS/LinuxX11 -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/Include -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/LinuxPC/Include -I/usr/X11R6/include -I../../.. -m32 -DBUILD_OGLES -Wall -DRELEASE -O2 ../../OGLESIntroducingPVRTools.cpp -o../LinuxPC/ReleaseX11/OGLESIntroducingPVRTools.o
+c+ OGLESIntroducingPVRTools ../LinuxPC/ReleaseX11/PVRShell.o
gcc -c -I/home/brenda/linux_em/SDKPackage/Tools/OGLES -I/home/brenda/linux_em/SDKPackage/Shell -I/home/brenda/linux_em/SDKPackage/Shell/API/KEGL -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/LinuxPC/Include -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/Include -I/home/brenda/linux_em/SDKPackage/Shell/OS/LinuxX11 -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/Include -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/LinuxPC/Include -I/usr/X11R6/include -I../../.. -m32 -DBUILD_OGLES -Wall -DRELEASE -O2 /home/brenda/linux_em/SDKPackage/Shell/PVRShell.cpp -o../LinuxPC/ReleaseX11/PVRShell.o
+c+ OGLESIntroducingPVRTools ../LinuxPC/ReleaseX11/PVRShellAPI.o
gcc -c -I/home/brenda/linux_em/SDKPackage/Tools/OGLES -I/home/brenda/linux_em/SDKPackage/Shell -I/home/brenda/linux_em/SDKPackage/Shell/API/KEGL -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/LinuxPC/Include -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/Include -I/home/brenda/linux_em/SDKPackage/Shell/OS/LinuxX11 -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/Include -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/LinuxPC/Include -I/usr/X11R6/include -I../../.. -m32 -DBUILD_OGLES -Wall -DRELEASE -O2 /home/brenda/linux_em/SDKPackage/Shell/API/KEGL/PVRShellAPI.cpp -o../LinuxPC/ReleaseX11/PVRShellAPI.o
+c+ OGLESIntroducingPVRTools ../LinuxPC/ReleaseX11/PVRShellOS.o
gcc -c -I/home/brenda/linux_em/SDKPackage/Tools/OGLES -I/home/brenda/linux_em/SDKPackage/Shell -I/home/brenda/linux_em/SDKPackage/Shell/API/KEGL -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/LinuxPC/Include -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/Include -I/home/brenda/linux_em/SDKPackage/Shell/OS/LinuxX11 -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/Include -I/home/brenda/linux_em/SDKPackage/Builds/OGLES/LinuxPC/Include -I/usr/X11R6/include -I../../.. -m32 -DBUILD_OGLES -Wall -DRELEASE -O2 /home/brenda/linux_em/SDKPackage/Shell/OS/LinuxX11/PVRShellOS.cpp -o../LinuxPC/ReleaseX11/PVRShellOS.o
+l+ ../LinuxPC/ReleaseX11/OGLESIntroducingPVRTools
g++ -o ../LinuxPC/ReleaseX11/OGLESIntroducingPVRTools ../LinuxPC/ReleaseX11/Image.o ../LinuxPC/ReleaseX11/OGLESIntroducingPVRTools.o ../LinuxPC/ReleaseX11/PVRShell.o ../LinuxPC/ReleaseX11/PVRShellAPI.o ../LinuxPC/ReleaseX11/PVRShellOS.o -/home/brenda/linux_em/SDKPackage/Tools/OGLES/Build/LinuxGeneric/../LinuxPC/ReleaseX11 -loglestools -Wl,--rpath-link=/home/brenda/linux_em/SDKPackage/Builds/OGLES/LinuxPC/Lib -L/home/brenda/linux_em/SDKPackage/Builds/OGLES/LinuxPC/Lib -lGLES_CM

d. cd to the directory where the program was built

>cd ../LinuxPC/ReleaseX11

 

e. run the program

>OGLESIntroducingPVRTools

PVRShell: EGL 1.3 initialized
Profile Chosen: MBXLITE
Segmentation fault

 



2. Full name of archive is SDK_OGLES-1.1_LINUX_PCEMULATION_2.04.24.0811.tar.gz


 



3. Renderer string:

(gdb) p str
$1 = (
    const GLubyte *) 0xb7f87ce0 "PowerVR PVRVFrame 4.2 MBXLite (Host GL: `Intel 965/963 Graphics Media Accelerator`) SDK Build: 2.04.24.0809"

 



jacekc wrote:


1.  Could You describe exactly the procedure that you have executed after unpacking the archive eg. command  you type to build this demo , shell variable you set (if any) before you compile and before you run demo and directory from which you are typing building command.


2. what is the full name of the archive of this SDK?. 


3.  please  put training course nr 4 , following line:


glGetString(GL_RENDERER);


in console you should see identication of pc emulation which I would like to ask you to present here.


Looking forward to have an response from you



#4

I changed the title to reflect that I discovered that the training program only faults when I'm using my Windows laptop as the display.  Since the Linux box I'm using for developement isn't very accessible, I've been using Putty to ssh to the Linux box.  To display openGL/X apps I have Xming running on my Windows laptop and I have Putty set up with X11 forwarding.  And this seems to work fine for glxgears and for training programs 1-5.  Training program 06_IntroducingPVRTools, however, gets a segmentation fault as described in my earlier post if I use this type of remote display.  Training program 6 does not get a segmentation fault if I display directly on the monitor for the Linux box.



Any suggestions welcomed.  Could it be some kind of xming configuration issue?  I'm surprised that the application, itself, would segmentation fault though.  I've been searching online for similar problems but so far no luck.    It's not very feasible for me to use the Linux box monitor so hope to get this working.


#5

Hi,

I'm sorry for such a delay. Unfourtunetly we do not have any experience with Xming and Putty with X forwarding. If you could send us configuration details of your Xming , Putty enviroment then we would like to recreate that situation and introduce necessery fixes.

Best Regards,


jacekc2009-04-16 16:19:30