adonthell-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Adonthell-devel] Re: SWIG 1.3.24


From: Kai Sterker
Subject: [Adonthell-devel] Re: SWIG 1.3.24
Date: Sat, 23 Apr 2005 10:03:05 +0100

On 4/22/05, Andrew Phillips <address@hidden> wrote:

> It may be a question without an answer, but are there any clues as to
> why SWIG keeps breaking the code that is dependent on it?

One answer might be that we use SWIG in a way it was not supposed to
be used. Specifically, we're not only calling our code from Python
(that is what SWIG is for), but also call Python from our code. For
latter, we need to access SWIG internals and if they change, our code
gets broken.

This time, all functions of the SWIG runtime library have been made
static, so we can no longer access them from our code. The workaround
for both v0.3.4 and v0.4 is to move the methods that call SWIG
internals into the SWIG wrapper, where they have access to the static
methods. That did not cause any harm in v0.3.4 where we only have one
Python module which is also statically linked. Therefore, it keeps
working with older versions of SWIG. In v0.4, where we have multiple,
dynamically linked Python modules, we can't continue using the old,
non-static SWIG runtime library. Otherwise we'd get duplicate symbols
when linking.

I do however hope that there won't be any problems with the next few
versions of SWIG ;-).

Kai




reply via email to

[Prev in Thread] Current Thread [Next in Thread]