Loris Bennett <loris.benn...@fu-berlin.de> wrote:
> Chris Green <c...@isbd.net> writes:
> 
> > Andy Smith <a...@strugglers.net> wrote:
> >> Hi Chris,
> >> 
> >> On Wed, Nov 06, 2024 at 10:54:17PM +0000, Chris Green wrote:
> >> > I have an OKI scanner which has a neat little linux app for running it
> >> > from a linux desktop. However it hasn't been updated from python 2.7
> >> > days and I'm looking at ways I might get it to run on my recently
> >> > upgraded Debian 12 system.
> >> 
> >> I'm pretty sure that someone somewhere is maintaining a Python 2
> >> compatible interpreter so I'd probably install that from source
> >> somewhere and use that as the interpreter just for this one app.
> >> 
> >> It is my understanding that no other project can call itself "Python"
> >> due to trademark laws so forks of Python 2 have to call themselves
> >> something else. One example would be Tauthon:
> >> 
> >>     https://github.com/naftaliharris/tauthon
> >> 
> >> I have never tried it.
> >> 
> >> It seems like a lot of work for what must be itself an abandoned app
> >> (otherwise it would have Python 3 support by now).
> >> 
> > It's a fairly old printer but it is still supported (drivers etc. for
> > windows 11) but they've never updated the Linux scanner driver, I
> > don't suppose there's that much demand for it.  It's a very neat
> > little app though so I'd like to keep using it.
> 
> The following suggestion is almost certainly overkill and probably more
> work to set up than simply porting the application to Python 3.
> 
I would if I could, but there are .so files built for Python 2 that
don't work in Python 3, my notes say:-

    So I tried to convert it all to Python 3, I had converted all my own code 
(including
    some Gtk stuff) to Python 3 so it seemed it should be possible.  All went 
well until:-

          File "/usr/libexec/okimfputl.new/guicom.py", line 66, in <module>
              import pyscand
          ImportError: /usr/libexec/okimfpdrv/pyscand.so: undefined symbol: 
_Py_ZeroStruct

    This is because the module pyscand.so has been compiled for Python 2 and 
produces
    the above error when you try using it from Python 3, since I don't have the 
source
    code for pyscand.so I'm stuck.


There isn't by any chance a tool/utility somewhere for converting
Python 2 .so files to Python 3 is there?

-- 
Chris Green
ยท

Reply via email to