voyageur / openglide

Git mirror of openglide CVS (http://openglide.sourceforge.net/)
GNU Lesser General Public License v2.1
48 stars 17 forks source link

Compiler warning and crash #13

Open arromdee opened 4 years ago

arromdee commented 4 years ago

Mageia Linux 7.1 64 bit:

glext.h:54: warning: "GL_GLEXT_VERSION" redefined

define GL_GLEXT_VERSION 16

In file included from /usr/include/GL/gl.h:2050, from /usr/include/SDL/SDL_opengl.h:48, from platform/window.h:23, from GlOgl.h:39, from GLutil.cpp:19: /usr/include/GL/glext.h:54: note: this is the location of the previous definition

define GL_GLEXT_VERSION 20190911

This then crashes with Tomb Raider, Dosbox-x most recent, and high level emulation using the modified glide2x.ovl and openglide. Examining the core dump shows that the crash happens inside the openglide library, in RenderAddTriangle() in GLRender.cpp, as soon as I get to a screen which uses Glide.

I don't know if the compile warning is warning me of something that might cause a crash. I know that the warning is caused by a conflict between the glext header in openglide and the one on my system but I have no idea how to fix it. I also don't know if there's a test program for openglide I can use to narrow problems down and/or prove they are caused by the wrapper.

voyageur commented 4 years ago

I have similar warning when compiling it in Gentoo, so I do not think this is relevant

It has been some time since I tried it though at the time it worked fine in Gentoo with simple ebuild: https://gitweb.gentoo.org/repo/gentoo.git/tree/media-libs/openglide/openglide-0.09_rc9_p20191120.ebuild and OpenGLid.ini (not sure if useful): https://gitweb.gentoo.org/repo/gentoo.git/tree/media-libs/openglide/files/OpenGLid.ini and plain dosbox with this patch: https://github.com/voyageur/openglide/blob/master/platform/dosbox/dosbox_glide.diff and glide2x.ovl: https://github.com/voyageur/openglide/blob/master/platform/dosbox/glide2x.ovl

And it worked. I now use mostly dosbox-staging, so I have not tried recently sorry

rderooy commented 4 years ago

@voyageur, he is referring to this bug report: https://github.com/joncampbell123/dosbox-x/issues/1428 that he raised.

I have however been able to compile your openglide fork just fine on Fedora 32 x86_64, even though I also get a bunch of "GL_GLEXT_VERSION" redefined warnings. And can run it with the latest DOSBox-X in glide pass-through mode with the same game without errors. I tried it with both Intel (4000 series) and AMD (RX590) graphics.

So my guess at this point, is that it is something to do with Mageia Linux.

I created a wiki page for DOSBox-X here, where I mention your fork: https://github.com/joncampbell123/dosbox-x/wiki/Guide%3ASetting-up-3dfx-Voodoo-in-DOSBox%E2%80%90X

The special GLIDE2X.OVL file is provided by DOSBox-X and if glide pass-through mode is (successfully) enabled, will appear automatically on the emulated Z: drive.

linkmauve commented 4 years ago

This is fixed now that #18 has been merged.