This is just FYI: swig 4.5.x no longer supports the python2 api, so e.g. gdal will not build any longer. For details, see https://www.swig.org/Doc4.5/Python.html#Python_nn53 (at the bottom of section 33.8). Renaming the function calls (e.g. s/PyOld/PyNew/) in the source fixes the issue. regards, d.s.