Dear Rootteam,
If this is what is happening, is it possible to "mark" libGX11.so, so that it knows that it is dependent on libCore.so? I would much prefer to use the shared libraries.
Sorry about reposting. I noted that the text below war grabeled in the earlier posting.
Marc
-----Original Message-----
From: owner-roottalk_at_lxbuild091.cern.ch
[mailto:owner-roottalk_at_lxbuild091.cern.ch] On Behalf Of Paul Russo
Sent: 15 July 2008 20:39
To: Marc de Kamps
Cc: roottalk_at_lxbuild091.cern.ch
Subject: Re: [ROOT] Python and C++ code calling ROOT
Marc,
This is happening because libGX11.so is dependent on symbols in libCore.so
but is not marked that way, so dlopen does not know it should load
libCore.so when it loads libGX11.so. The ROOT application itself uses
a plugin architecture with external metadata to determine the
interdependencies
between the various shareable libraries that together make up the ROOT
library set (see the *.rootmap files in $ROOTSYS/lib).
The simplest way around this problem for you is to build a static version of the root library from the source code using "make static". This will make a libROOT.a file which you can then link with your code, avoiding all problems with *.so files.
Marc de Kamps wrote:
> Hi,
>
>
>
> As I mentioned last week I have C++ code which calls ROOT. Using SWIG I
> create a Python module. The idea is that from Python I can call my C++
> routines, which call ROOT.
>
>
>
> This turns out to be problematic. I have to link against a library which
> is linked against the core ROOT libraries (root-config -libs). Python
> then crashes on importing my SWIG generated libraries.
>
>> >> import Dynamic
>> >> import Dynamic
>> >>
This archive was generated by hypermail 2.2.0 : Sat Aug 02 2008 - 23:50:02 CEST