Re: SWIG 4.3 Deprecated t_output_helper and backwards compatibility

Julien Marrec <[email protected]> Tue, 18 Jun 2024 08:54:23 +0200
Newsgroups gmane.comp.programming.swig
Message-ID <CAEqKKtxNyq_NV7s=RYbkK=Kd5_vTUN4KLMErUdtHscrRZwkAtQ@mail.gmail.com>
--===============8540575425290359717==
Content-Type: multipart/alternative; boundary="000000000000ecc910061b248d4f"

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

Macros?

SWIG_VERSION is a hexadecimal integer such as 0x010311 (corresponding to
SWIG-1.3.11).

#if SWIG_VERSION < 0x040300
   // Swig before 4.3.0
#else
  // Swig at 4.3.0 and above
#endif
--
Julien Marrec, EBCP, BPI MFBA
Owner at EffiBEM <http://www.effibem.com>
T: +33 6 95 14 42 13

LinkedIn (en <https://www.linkedin.com/in/julienmarrec>) *| *(fr
<https://fr.linkedin.com/in/julienmarrec/fr>) :
<http://www.linkedin.com/in/julienmarrec>


Le lun. 17 juin 2024 =C3=A0 18:52, Seth G <[email protected]> a =C3=
=A9crit :

> Hi all,
>
> We ran into some build issues with the latest SWIG master (4.3.0)  - whic=
h
> removes t_output_helper.
>
> I've updated the code as suggested in the release notes by using
> SWIG_Python_AppendOutput. See
> https://github.com/MapServer/MapServer/pull/7083/files
>
> Is there a way to make this change compatible with both 4.3.0 and previou=
s
> 4.x SWIG builds?
>
> SWIG_Python_AppendOutput expects a new $is_void parameter in 4.3.0 but
> won't build in previous versions when added, e.g.
> SWIG_Python_AppendOutput($result,r,1);
>
> Thanks for any hints,
>
> Seth
>
>
>
>
> _______________________________________________
> Swig-user mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/swig-user
>

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

<div dir=3D"ltr"><div>Macros?</div><div><br></div><div>SWIG_VERSION is a he=
xadecimal integer such as 0x010311 (corresponding to SWIG-1.3.11).</div><di=
v><br></div><div>#if SWIG_VERSION &lt; 0x040300</div><div>=C2=A0=C2=A0 // S=
wig before 4.3.0<br></div><div>#else</div><div>=C2=A0 // Swig at 4.3.0 and =
above<br></div><div>#endif</div><div><div dir=3D"ltr" class=3D"gmail_signat=
ure" data-smartmail=3D"gmail_signature"><div dir=3D"ltr"><div><div dir=3D"l=
tr"><div><div dir=3D"ltr"><div>--<br>Julien Marrec, EBCP, BPI MFBA<br>Owner=
 at <a href=3D"http://www.effibem.com" target=3D"_blank">EffiBEM</a><br>T: =
+33 6 95 14 42 13<br><span style=3D"color:rgb(0,0,0)"><br></span><span styl=
e=3D"color:rgb(0,0,0)">LinkedIn (<a href=3D"https://www.linkedin.com/in/jul=
ienmarrec" target=3D"_blank">en</a>)<span style=3D"color:rgb(0,0,0)"> <i>| =
</i></span>(<a href=3D"https://fr.linkedin.com/in/julienmarrec/fr" target=
=3D"_blank">fr</a>) : </span><br><span style=3D"color:rgb(0,0,0)"><a href=
=3D"http://www.linkedin.com/in/julienmarrec" target=3D"_blank"></a></span><=
/div></div></div></div></div></div></div></div><br></div><br><div class=3D"=
gmail_quote"><div dir=3D"ltr" class=3D"gmail_attr">Le=C2=A0lun. 17 juin 202=
4 =C3=A0=C2=A018:52, Seth G &lt;<a href=3D"mailto:[email protected]">=
[email protected]</a>&gt; a =C3=A9crit=C2=A0:<br></div><blockquote cl=
ass=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid=
 rgb(204,204,204);padding-left:1ex">Hi all,<br>
<br>
We ran into some build issues with the latest SWIG master (4.3.0)=C2=A0 - w=
hich removes t_output_helper. <br>
<br>
I&#39;ve updated the code as suggested in the release notes by using SWIG_P=
ython_AppendOutput. See <a href=3D"https://github.com/MapServer/MapServer/p=
ull/7083/files" rel=3D"noreferrer" target=3D"_blank">https://github.com/Map=
Server/MapServer/pull/7083/files</a><br>
<br>
Is there a way to make this change compatible with both 4.3.0 and previous =
4.x SWIG builds?<br>
<br>
SWIG_Python_AppendOutput expects a new $is_void parameter in 4.3.0 but won&=
#39;t build in previous versions when added, e.g. SWIG_Python_AppendOutput(=
$result,r,1);<br>
<br>
Thanks for any hints,<br>
<br>
Seth<br>
<br>
<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>

--000000000000ecc910061b248d4f--


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


--===============8540575425290359717==
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

--===============8540575425290359717==--