Hello All:
After tracing through code I see the one difference than when I was building on
the previous Mac version before upgrading to SnowLeopard. I noticed in the
OpenThreads/Config file a check for deployment >= 10.5 and it was using a BSD
Atomic operation than the standard mutex lock operation. I did a test and
modified this to comment out the use of the BSD. This actually fixed all
crashes in the Qt frameworks and we now can run successfully.
I am not sure but it might be better to leave the OpenThreads/Config file as
the default Mutex lock Atomic operation and let one manually change to other
Atomic operation on their build system.
Take care
Garrett
On Jan 21, 2010, at 10:36 AM, Garrett Potts wrote:
> Hello All:
>
> I have found a problem that I have no clue how to work around. I think it's
> the build but not sure. My platform is Snow Leopard using 64 bit builds and
> the 4.2.1 compiler. It started when I was building and upgrading the current
> GUI frameworks we have to build against OSG. There are probably other areas
> but It stop with a core dump when allocating:
>
> osg::ref_ptr< osgViewer::GraphicsWindowEmbedded> gw = new
> osgViewer::GraphicsWindowEmbedded(0,0,width(),height());
>
>
> So what I did to replicate the crash is create a qmake directory structure
> and copied out the osgviewerQt example. I split it off into a framework
> where the AdapterWidget.cpp is added to aframework and then I build an
> application called osgviewerQt. The main in the application looks like this:
>
> #include <QtGui/QApplication>
> #include <osg/ArgumentParser>
> #include <iostream>
> #include <osgviewerQt/ViewerQt.h>
>
> int main( int argc, char **argv )
> {
> QApplication a( argc, argv );
>
>
> osg::ArgumentParser arguments(&argc, argv);
>
> osg::ref_ptr<osgViewer::GraphicsWindowEmbedded> gw = new
> osgViewer::GraphicsWindowEmbedded(0,0,1024,1024);
> }
>
>
> All I wanted to simulate was creating a Qt framework and then calling the
> instantiation of GraphicsWindowEmbedded in an applicaiton. The above core
> dumps everytime on the snow leopard build. I know it has to do something
> with the build but I have no clue what the correct options should be.
>
> If anyone wants to try it I can tar up the small test above and you will have
> to dfine an environment variable called OSG_FRAMEWORKS before running the
> qmake in the src directory and the apps/osgviewerQt directory.
>
>
> I am hoping someone has some insight into this for I am at the point where I
> have no clue what to try.
>
> Thank you in advance for any insight and take care
>
>
> Garrett
>
> _______________________________________________
> osg-users mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org