On Wednesday 03 September 2008 16:52, Alberto Luaces wrote: > Mathias, > > comments follow: > > El Miércoles 03 Septiembre 2008ES 16:08:46 Mathias Fröhlich escribió: > [...] > > > > Although I always "make install" my compilings, I decided to try the > > > patch. However it is not working for me: > > > > [...] > > > > > so they are linked to the build tree's libraries, but: > > > > > > $ ./osgviewer cow.osg > > > Warning: Could not find plugin to read objects from file "cow.osg". > > > ./osgviewer: No data loaded > > > > That is not supposed to work. Also not with that patch. > > Tell osg you want to have it installed in the prefix say /tmp/foo, then > > the installed binaries - when the binaries have an rpath included - will > > search in /tmp/foo/plugins-<version> with that patch. Without that patch > > plugins are only found if you set LD_LIBRARY_PATH or OSG_LD_LIBRARY_PATH. > > If I install OSG to my personal, non-system prefix ($HOME/usr), CMake does > not include the rpaths into the libraries, so I have to use LD_LIBRARY_PATH > to at least be able to run the program, even if I don't use any plugin. > Have you found of telling it so? I only found CMAKE_SKIP_RPATH, but I think > it does quite the opposite.
export LDFLAGS="-Wl,-rpath,<path where you will install osg libs>" cmake ... make install And you do not need a LD_LIBRARY_PATH for osgviewer for example. Anyway, sometimes it is more interresting to run an own application built on top of osg. And usually you have the build system of that own application in your hands ... :) > If I try to execute OSG applications from the build directory, rpath is > present in the binaries, so I can run them, but the plugins are not found > even they are already installed (in $HOME/usr/lib64/osgPlugins-2.7.2) Hmm, strange ... I could now reproduce that, with a fresh cmake run here. There is some ordering probme that seems to appear when I start with a fresh build tree. The problem was here that DYNAMIC_OPENSCENEGRAPH cmake varialbe was not yet set. Reordering that IF made it work here. Sorry ... Attached the updated change ... Greetings Mathias -- Dr. Mathias Fröhlich, science + computing ag, Software Solutions Hagellocher Weg 71-75, D-72070 Tuebingen, Germany Phone: +49 7071 9457-268, Fax: +49 7071 9457-511 -- Vorstand/Board of Management: Dr. Bernd Finkbeiner, Dr. Florian Geyer, Dr. Roland Niemeier, Dr. Arno Steitz, Dr. Ingrid Zech Vorsitzender des Aufsichtsrats/ Chairman of the Supervisory Board: Prof. Dr. Hanns Ruder Sitz/Registered Office: Tuebingen Registergericht/Registration Court: Stuttgart Registernummer/Commercial Register No.: HRB 382196
default-path.tar.bz2
Description: application/tbz
_______________________________________________ osg-submissions mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org
