Re: Should Swig-generated shared libraries be versioned (.so linking to .x.y.z.so)?

William S Fulton <[email protected]> Wed, 22 May 2024 07:20:01 +0100
Newsgroups gmane.comp.programming.swig
Message-ID <CANGqftCsebJqAcr+mPm2JFVkyuP=pzsWAPiK1f05XA+u_Wse9g@mail.gmail.com>
--===============6135020706344297185==
Content-Type: multipart/alternative; boundary="000000000000e34161061904ee1e"

--000000000000e34161061904ee1e
Content-Type: text/plain; charset="UTF-8"

I'd have thought that versioning will work. SWIG just generates the source
code and it is up to you to compile it appropriately for your target
language. Probably best to consult your operating system's documentation on
your dynamic linker and versioning as well docs on your target language and
versioned shared objects.

William

On Tue, 7 May 2024 at 18:34, Joachim Wuttke <[email protected]> wrote:

> Linux convention wants shared libraries to be versioned,
> with less specific symlinks:
>
>     libfoo.so.1.54.0
>     libfoo.so.1.54   -> libfoo.so.1.54.0
>     libfoo.so.1      -> libfoo.so.1.54
>     libfoo.so        -> libfoo.so.1
>
> Would that also be good practice for Swig-generated
> shared libraries that are meant to be used as plugins?
>
> The Swig docs have _example.so without version number though.
>
>
> _______________________________________________
> Swig-user mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/swig-user
>

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

<div dir=3D"ltr"><div>I&#39;d have thought that versioning will work. SWIG =
just generates the source code and it is up to you to compile it appropriat=
ely for your target language. Probably best to consult your operating syste=
m&#39;s documentation on your dynamic linker and versioning as well docs on=
 your target language and versioned shared objects.</div><div><br></div><di=
v>William<br> </div></div><br><div class=3D"gmail_quote"><div dir=3D"ltr" c=
lass=3D"gmail_attr">On Tue, 7 May 2024 at 18:34, Joachim Wuttke &lt;<a href=
=3D"mailto:[email protected]">[email protected]</a>&gt; wrote:<br=
></div><blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;=
border-left:1px solid rgb(204,204,204);padding-left:1ex">Linux convention w=
ants shared libraries to be versioned,<br>
with less specific symlinks:<br>
<br>
=C2=A0 =C2=A0 libfoo.so.1.54.0<br>
=C2=A0 =C2=A0 libfoo.so.1.54=C2=A0 =C2=A0-&gt; libfoo.so.1.54.0<br>
=C2=A0 =C2=A0 libfoo.so.1=C2=A0 =C2=A0 =C2=A0 -&gt; libfoo.so.1.54<br>
=C2=A0 =C2=A0 libfoo.so=C2=A0 =C2=A0 =C2=A0 =C2=A0 -&gt; libfoo.so.1<br>
<br>
Would that also be good practice for Swig-generated<br>
shared libraries that are meant to be used as plugins?<br>
<br>
The Swig docs have _example.so without version number though.<br>
<br>
<br>
_______________________________________________<br>
Swig-user mailing list<br>
<a href=3D"mailto:[email protected]" target=3D"_blank">Swig-u=
[email protected]</a><br>
<a href=3D"https://lists.sourceforge.net/lists/listinfo/swig-user" rel=3D"n=
oreferrer" target=3D"_blank">https://lists.sourceforge.net/lists/listinfo/s=
wig-user</a><br>
</blockquote></div>

--000000000000e34161061904ee1e--


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


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

_______________________________________________
Swig-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/swig-user

--===============6135020706344297185==--