laumaya / GLC_lib

GLC_lib is a C++ library for high performance 3D application based on OpenGL and Qt4 GUI
http://www.glc-lib.net
Other
62 stars 31 forks source link

Segmentation fault when GLC lib is built with zlib and quazip built-in libraries. #42

Open tvataire opened 1 year ago

tvataire commented 1 year ago

On linux systems embedded zlib and quazip libraries cause a segfault when a binary is linked against the GLC library.

With embedded libraries :

$ ./glc_player 
libpng warning: iCCP: known incorrect sRGB profile
libpng error: unexpected zlib return code
libpng warning: iCCP: known incorrect sRGB profile
libpng error: unexpected zlib return code
...
libpng error: unexpected zlib return code
libpng warning: iCCP: known incorrect sRGB profile
libpng error: unexpected zlib return code
QOpenGLTexture::setData() tried to set a null image
Erreur de segmentation (core dumped)

With the system ones :

$ ./glc_player 
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
...
libpng warning: iCCP: known incorrect sRGB profile
libpng warning: iCCP: known incorrect sRGB profile
QOpenGLTexturePrivate::destroy() called without a current context.
...

On Unix systems, the GLC lib should be build using system libraries instead of the build-in ones.