Re: [ITK-users] Problem loading dynamic library linked to ITK from a program also linked to ITK

Dženan Zukić <[email protected]> Fri, 28 Sep 2018 12:59:59 -0400
Newsgroups gmane.comp.lib.itk.user
Message-ID <CAPf2UMSDETUHB1_9Nb62FR0_Nt7tOcDJ=AyR_b=s_Ce5GQWknw@mail.gmail.com>
--===============0829556537==
Content-Type: multipart/alternative; boundary="000000000000a1e7980576f1635c"

--000000000000a1e7980576f1635c
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

Hi Baptiste,

can you re-post the question on the forum <https://discourse.itk.org/>?

Regards,
D=C5=BEenan

On Fri, Sep 28, 2018 at 11:36 AM BaptisteL <[email protected]> wrote:

> Hello all,
>
> I am trying to load at runtime a dynamic library using ITK (let's call it
> lib.so), within a program also linked to ITK.
> To do this, I am using :
>
> void* handle =3D dlopen("lib.so", RTLD_LOCAL | RTLD_LAZY)
>
> but it crashes (I receive an H5::DataSpaceIException).
>
> This works when I remove linking to ITK from the program that use the
> library, or when I remove it from the library itself, so I guess I have
> conflicting links between both programs, but I can't figure it out.
>
> Thank you !
>
>
>
>
>
>
> --
> Sent from: http://itk-insight-users.2283740.n2.nabble.com/
> The ITK community is transitioning from this mailing list to
> discourse.itk.org. Please join us there!
> ________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Kitware offers ITK Training Courses, for more information visit:
> http://www.kitware.com/products/protraining.php
>
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> https://itk.org/mailman/listinfo/insight-users
>

--000000000000a1e7980576f1635c
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div class=3D"gmail_default" style=3D"font-family:verdana,=
sans-serif;font-size:small">Hi Baptiste,</div><div class=3D"gmail_default" =
style=3D"font-family:verdana,sans-serif;font-size:small"><br></div><div cla=
ss=3D"gmail_default" style=3D"font-family:verdana,sans-serif;font-size:smal=
l">can you re-post the question on the <a href=3D"https://discourse.itk.org=
/">forum</a>?</div><div class=3D"gmail_default" style=3D"font-family:verdan=
a,sans-serif;font-size:small"><br></div><div class=3D"gmail_default" style=
=3D"font-family:verdana,sans-serif;font-size:small">Regards,</div><div clas=
s=3D"gmail_default" style=3D"font-family:verdana,sans-serif;font-size:small=
">D=C5=BEenan</div></div><br><div class=3D"gmail_quote"><div dir=3D"ltr">On=
 Fri, Sep 28, 2018 at 11:36 AM BaptisteL &lt;<a href=3D"mailto:batlaurent@h=
otmail.com">[email protected]</a>&gt; wrote:<br></div><blockquote clas=
s=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;pad=
ding-left:1ex">Hello all,<br>
<br>
I am trying to load at runtime a dynamic library using ITK (let&#39;s call =
it<br>
lib.so), within a program also linked to ITK.<br>
To do this, I am using :<br>
<br>
void* handle =3D dlopen(&quot;lib.so&quot;, RTLD_LOCAL | RTLD_LAZY)<br>
<br>
but it crashes (I receive an H5::DataSpaceIException).<br>
<br>
This works when I remove linking to ITK from the program that use the<br>
library, or when I remove it from the library itself, so I guess I have<br>
conflicting links between both programs, but I can&#39;t figure it out.<br>
<br>
Thank you !<br>
<br>
<br>
<br>
<br>
<br>
<br>
--<br>
Sent from: <a href=3D"http://itk-insight-users.2283740.n2.nabble.com/" rel=
=3D"noreferrer" target=3D"_blank">http://itk-insight-users.2283740.n2.nabbl=
e.com/</a><br>
The ITK community is transitioning from this mailing list to <a href=3D"htt=
p://discourse.itk.org" rel=3D"noreferrer" target=3D"_blank">discourse.itk.o=
rg</a>. Please join us there!<br>
________________________________<br>
Powered by <a href=3D"http://www.kitware.com" rel=3D"noreferrer" target=3D"=
_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at<br>
<a href=3D"http://www.kitware.com/opensource/opensource.html" rel=3D"norefe=
rrer" target=3D"_blank">http://www.kitware.com/opensource/opensource.html</=
a><br>
<br>
Kitware offers ITK Training Courses, for more information visit:<br>
<a href=3D"http://www.kitware.com/products/protraining.php" rel=3D"noreferr=
er" target=3D"_blank">http://www.kitware.com/products/protraining.php</a><b=
r>
<br>
Please keep messages on-topic and check the ITK FAQ at:<br>
<a href=3D"http://www.itk.org/Wiki/ITK_FAQ" rel=3D"noreferrer" target=3D"_b=
lank">http://www.itk.org/Wiki/ITK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href=3D"https://itk.org/mailman/listinfo/insight-users" rel=3D"noreferre=
r" target=3D"_blank">https://itk.org/mailman/listinfo/insight-users</a><br>
</blockquote></div>

--000000000000a1e7980576f1635c--

--===============0829556537==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

The ITK community is transitioning from this mailing list to discourse.itk.org. Please join us there!
________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html

Kitware offers ITK Training Courses, for more information visit:
http://www.kitware.com/products/protraining.php

Please keep messages on-topic and check the ITK FAQ at:
http://www.itk.org/Wiki/ITK_FAQ

Follow this link to subscribe/unsubscribe:
https://itk.org/mailman/listinfo/insight-users

--===============0829556537==--