TkinterWeb
TkinterWeb copied to clipboard
/32-bit/Tkhtml30.so: cannot open shared object file: No such file or directory
Trying to install on a raspberry pi zero running 'Lite' but with openbox and lightdm. This is with the latest Bullseye distribution.
I added some try - except code to find some issues and ran into this one. I see the file in the directory so it doesn't appear to be that.
/home/pi/.local/lib/python3.9/site-packages/tkinterweb/tkhtml/Linux/32-bit/Tkhtml30.so": /home/pi/.local/lib/python3.9/site-packages/tkinterweb/tkhtml/Linux/32-bit/Tkhtml30.so: cannot open shared object file: No such file or directory
It took a bit of snooping but I also found another earlier issue. I had to install libopenjp2-7
. I was getting a non-descriptive import error.
Hi,
That's quite odd. Unfortunately, 32-bit Linux hasn't been tested on very much. After installing libopenjp2-7
, does this package work as expected?
I'm sorry. Poor communication on my part - I should have posted 2 different issues. Here is a link to the issue related to the libopenjp2-7: https://github.com/Andereoo/TkinterWeb/issues/25
With regard to the error in the title of this issue, I have not found a solution. As stated, the Tkhtml30.so does indeed appear to exist where it's supposed to be. It seems that this is a "nested" error message (inherited?) and that the "No such file or directory" message is referencing a resource which has not been explicitly identified. We will have to investigate.
No problem!
Could you make a Python file in your TkinterWeb directory and run the below code for me?
import os, glob
def searchdir():
files = glob.glob("**/**", recursive=True)
for file in files:
path = os.path.join(".", file)
size = os.path.getsize(path)
print(file, end=":\n")
print(" Size: {}".format(size))
if path.endswith(".tcl"):
with open(path, "r") as handle:
content = handle.read()
print(" Content: \n{}".format(content))
print()
searchdir()
If you could upload the output, that would be great. It should help rule out whether or not something went wrong with the installation.
Give this a try.
anderoo_results.txt
It looks like all of the files are in the right places. I think this may be related to #25. I'll come back to this when we work out the other thread.
I rebuilt the latest release of tkhtml on my raspberry pi and have gotten past this error, I have attached the files. Interesting note to add: The files work for me in /lib/Tkhtml3.0 (which is the install folder) but not in the tkinterweb folder
However I have now ran into a segfault in the built shared object, at least it's progress I guess. tkhtml_linux_32.zip
Managed to find this github: https://github.com/olebole/tkhtml3 After building it seems to work perfectly for me so here are the files: Tkhtml3.0.zip
Again these are located in /lib/Tkhtml3.0 for me, not the tkinterweb folder so your usage may vary
Hi!
Sorry for the late response. I'm glad that you have found a version that works. I have uploaded one of my versions (which has some modifications that TkinterWeb uses to prevent crashes). If you have a chance I would appreciate it if you could try compiling it and letting me know what happens. The source is here. Also, could you please let me know what your architecture is?
Thanks!
I'll try it out right now, thanks. I'm running this on a raspberry pi 4 32-bit
Built and runs fine, no crashes or segfaults. Thanks a lot! Let me know if I can be of any use with something else.
That's great to know. If you have a chance, I'd appreciate it if you could help me out with a couple of things.
- Could you please attach the output of
arch
anduname -m
. - Seeing as you have compiled Tkhtml on your own, I'm guessing that you have Tcl/Tk installed. Try running Tcl (if I remember correctly the command should be
tclsh
). Then use theload
command to load the defaulttkinterweb/tkhtml/Linux/32-bit/Tkhtml30.so
file. Let me know what happens. - If you could also upload the new
.so
file that you compiled with the code I uploaded that would be great.
Thank you very much!
Can do, but it will have to be next week when I'm back in the office.
No worries! Whenever you get a chance.
arch/uname -m both give "armv7l" trying to load the original Tkhtml30.so gives: "cannot open shared object file: No such file or directory" tkinterweb_build_tkhtml.zip
Thanks! It looks like most Linux distros support either i386
or x86-64
packages (TkinterWeb supplies both). Raspberry pi, though, instead uses the ARM
architecture (it's more cost-efficient) and seems to have no support for most other Linux packages. When you run TkinterWeb, it checks the OS and finds that it is running a 32-bit OS, and so tries to load the i386
Tkhtml library, which is unsupported by P (I'm still not entirely sure why the error is No such file or directory
when the file actually exists but instead is incompatible).
I'm going to add the armv7l
package and look for an efficient way to get TkinterWeb to discern the difference between i386
and armv7l
so that we can fix this problem.
Hi! Apologies for the (very long) delay. I've added a binary for Raspberry Pi. Let me know if it works now!
Hey! Thanks for the update :) Sadly the project was put on hold, so I'm no longer working on it. However I'll see if I can get a quick setup running sometime this week.
No worries; @WGandy let me know if the update works!