[vbox-dev] Minimalist OpenGL program crashing

Otacílio otacilio.neto at bsd.com.br
Thu Nov 10 12:07:49 UTC 2016


I'm using this minimalist program to test OpenGL. When running on a true 
machine (FreeBSD 11, clang 3.8.0) this program runs fine. But, when 
compiling and running in a Virtualbox guest with 
virtualbox-ose-additions-5.1.8 installed (FreeBSD 11, clang 3.8.0, 
OpenGL enabled)  I'm getting a core dump when the program exits. So its 
not clear to me if this is a FreeBSD port problem or not. So, please, I 
wold like ask you to compile and running in your's guest machine running 
Linux or FreeBSD and report to me the results.


#include <stdio.h>
#include <GL/glew.h>
#include <GL/gl.h>
#include <GL/glu.h>
#include <GL/glut.h>
#include <GL/glext.h>

int main(int argc, char **argv) {

         glutInit(&argc, argv);

         printf("OpenGL version supported by this platform (%s): \n",

         fprintf(stdout, "Exiting...\n");

         return 0;

Compiler command:

cc -I/usr/local/include -L/usr/local/lib -o testegl testegl.c -lGL 
-lGLEW -lGLU   -lglut

My results in a guest machine:

[ota at nostromo /usr/home/ota/Desktop]$ ./testegl
OpenGL version supported by this platform (2.1 Chromium 1.9):
Segmentation fault (imagem do núcleo gravada)

Thanks a lot!



More information about the vbox-dev mailing list