Ryan Pavlik writes: > On Wed, May 18, 2011 at 7:03 AM, Alberto Luaces <[email protected]> wrote: > > Hi, > > Ryan Pavlik writes: > > >> fix-linux-link-libdl: I got an unresolved symbol error when linking > >>> osgviewer to > >>> the osg and osgViewer libraries pointing to symbols from libdl (using > >>> Ubuntu > >>> 10.04). This explicitly links with libdl when "linux" is in the target > >>> system > >>> name, fixing the build error on my machine. > >>> > >> > >> Interesting. How long has this issue been present? 2.8.4? 2.8.3? 2.8.2? > >> > > > > Not sure - I have a 2.8.3 PPA (Ubuntu .deb package builder) that works > fine, > > so I presume sometime after that point. I'm never quite sure when I > need to > > link libdl, but unresolved symbol errors are a pretty easy way to tell. > :) > > Actually it was happily taken into account since 2010 (see > r11055). However, it seems that r12208 introduced a regression that > kicked out libdl from the linker command for libosg. Just linking with > -ldl all the libraries from the OSG is not a clean solution, since if I > recall correctly, only libosg needs to load shared objects at runtime -- > the plugins. > > I'm going to see if I can get something by playing with those > TARGET_*_LIBRARIES variables. > > -- > Alberto > > Great, thanks for looking in to this further. I have one more small > improvement for osgconv in the pipeline that I'm hoping to get in in time for > 2.8.5, so I'm happy to hear there's other > work to be done. > > Ryan
Hi Ryan, I spoke too soon. I have checked that there is not a regression in trunk. libdl is added to the linker command as needed, that is, only for libosg and libosgDB. The problem with 2.8.4-rc2 is that is a branch which predates the revision where the change was added. Therefore the trivial solution is to backport the changes in r11055 to the branch in order to benefit from it. I also remember that someone added a slight modification over this patch in order to fix the build in FreeBSD. I will post the revision number if I find it. -- Alberto _______________________________________________ osg-submissions mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org
