[osg-users] Release built OSG libs with debug built app...
All, I believe this issue has been addressed before but I can't find the previous discussion. Therefore I will ask again... Is there a way to get Release-built OSG libs to play nicely with an app that is built with Debug? Right now if I link with Release-built OSG libs, my app (built with Debug option) doesn't work. If I link with Debug-built OSG libs, things work fine. If I built my app with Release, then it also works fine. Because OSG is so slow when using the Debug libs, I would like to avoid using them since I have no need to debug down into OSG code. I do need to debug my app. I'm using VS 2008 SP1 on Windows 7... Thank you! Shayne -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=45809#45809 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Release built OSG libs with debug built app...
On Mon, Feb 27, 2012 at 11:34 AM, Shayne Tueller shayne.tuel...@hill.af.mil wrote: All, I believe this issue has been addressed before but I can't find the previous discussion. Therefore I will ask again... Is there a way to get Release-built OSG libs to play nicely with an app that is built with Debug? Right now if I link with Release-built OSG libs, my app (built with Debug option) doesn't work. If I link with Debug-built OSG libs, things work fine. If I built my app with Release, then it also works fine. Basically, no. However, I believe you could build a release build of your app with no optimization and with all debug symbols included. This should allow you to debug your code (though not as completely as a full Debug build) from within a release build. -- Chris 'Xenon' Hanson, omo sanza lettere. xe...@alphapixel.com http://www.alphapixel.com/ Training • Consulting • Contracting 3D • Scene Graphs (Open Scene Graph/OSG) • OpenGL 2 • OpenGL 3 • OpenGL 4 • GLSL • OpenGL ES 1 • OpenGL ES 2 • OpenCL Digital Imaging • GIS • GPS • Telemetry • Cryptography • Digital Audio • LIDAR • Kinect • Embedded • Mobile • iPhone/iPad/iOS • Android ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Release built OSG libs with debug built app...
On 02/27/2012 02:12 PM, Chris Hanson wrote: On Mon, Feb 27, 2012 at 11:34 AM, Shayne Tueller shayne.tuel...@hill.af.mil mailto:shayne.tuel...@hill.af.mil wrote: All, I believe this issue has been addressed before but I can't find the previous discussion. Therefore I will ask again... Is there a way to get Release-built OSG libs to play nicely with an app that is built with Debug? Right now if I link with Release-built OSG libs, my app (built with Debug option) doesn't work. If I link with Debug-built OSG libs, things work fine. If I built my app with Release, then it also works fine. Here is an explanation of why this doesn't work... http://msdn.microsoft.com/en-us/library/ms235460%28v=vs.80%29.aspx The article talks about the differences between msvcrt.dll and msvcrversion.dll, but the same problem exists when you mix debug and release runtime libraries. You can't pass a pointer generated by your app in debug mode (using the debug version of the C runtime) to OSG in release mode (using the release version of the C runtime). The key is the C runtime flag sent to the compiler. Either compile everything with /MD (Multithreaded DLL) or /MDd (Multithreaded debug DLL). Mixing them is bad. However, I believe you could build a release build of your app with no optimization and with all debug symbols included. This should allow you to debug your code (though not as completely as a full Debug build) from within a release build. Yeah, this works (sort of). --J ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org