This may or may not be helpful, but if you take a look at the CorsixTH project (<meta http-equiv="content-type" content="text/html; charset=utf-8"><a href="http://code.google.com/p/corsix-th/">http://code.google.com/p/corsix-th/</a>), they've implemented Lua persistence without using Pluto, and it appears to be quite portable (Win/OSX/Linux at least). I'm pretty sure they're implementation is specific to their project, but if it's a viable option, it would allow you to drop both Pluto and Lua as dependencies, as it wouldn't force you to maintain a specific Lua version in trunk.<br>
<br><div class="gmail_quote">On Tue, Oct 19, 2010 at 7:18 AM, Max Horn <span dir="ltr"><<a href="mailto:max@quendi.de">max@quendi.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Hi there,<br>
<br>
I just saw bug report #3090234 "SWORD25: Code analysis warnings", and that pointed out the following issue (amongst others):<br>
<br>
d:\sources\scummvm\scummvm\engines\sword25\util\lua\ldo.cpp(118): warning C4611: interaction between '_setjmp' and C++ object destruction is non-portable<br>
This is not an analysis warning. It might need to be disabled in the property file when generating the project files with create_msvc if deemed invalid<br>
<br>
Looking at luaconf.h, it turns out that the Lua code indeed makes use of setjmp. That's rather bad news, as setjmp is not that portable. Instead of setjmp, Lua can apparently also use C++ exceptions -- something we have tried to avoid so far (and disabled in our build system). Still, I figure it might cause less harm to use those than to use setjmp. But either way, we'll have to deal with this.<br>

<br>
On the short run, we could get along by adding a setjmp configure check, and disabling the sword25 engine if setjmp is not present and working.<br>
<br>
On the long run, we could remove the Lua code again and rely on it being provided as an external dependency, which would be free to use setjmp or throw/catch.<br>
<br>
However, we then still would have the problem of pluto being tightly linked to the exact Lua version... However, note that from the pluto homepage <<a href="http://lua-users.org/wiki/PlutoLibrary" target="_blank">http://lua-users.org/wiki/PlutoLibrary</a>>, though, it sounds as if any Lua 5.1.x version would be acceptable. Is that correct?<br>

<br>
Anyway, as I see it, pluto may have some other issues. For example, from some things I read while googling around, I got the impression that pluto does not store data in a platform independent way. Hence, sword25 savestates would not be portable across platforms, assuming they make use of pluto. If anybody knows more about this, then please chime in!<br>

<br>
The Pluto project also seems to be dormant (see e.g. this unhandled bug report about issues on 64bit systems: <<a href="http://luaforge.net/tracker/index.php?func=detail&aid=47527&group_id=31&atid=216" target="_blank">http://luaforge.net/tracker/index.php?func=detail&aid=47527&group_id=31&atid=216</a>>).<br>

<br>
There is a fork on github <<a href="http://github.com/hoelzro/pluto" target="_blank">http://github.com/hoelzro/pluto</a>> which might be interesting to investigate, it even provide a roadmap. Well, and we could also simply try to contact the original Pluto author as well as the fork's author...<br>

<br>
<br>
Cheers,<br>
Max<br>
<br>
<br>
------------------------------------------------------------------------------<br>
Download new Adobe(R) Flash(R) Builder(TM) 4<br>
The new Adobe(R) Flex(R) 4 and Flash(R) Builder(TM) 4 (formerly<br>
Flex(R) Builder(TM)) enable the development of rich applications that run<br>
across multiple browsers and platforms. Download your free trials today!<br>
<a href="http://p.sf.net/sfu/adobe-dev2dev" target="_blank">http://p.sf.net/sfu/adobe-dev2dev</a><br>
_______________________________________________<br>
Scummvm-devel mailing list<br>
<a href="mailto:Scummvm-devel@lists.sourceforge.net">Scummvm-devel@lists.sourceforge.net</a><br>
<a href="https://lists.sourceforge.net/lists/listinfo/scummvm-devel" target="_blank">https://lists.sourceforge.net/lists/listinfo/scummvm-devel</a><br>
</blockquote></div><br>