tkinterdnd2 icon indicating copy to clipboard operation
tkinterdnd2 copied to clipboard

Not compiling on ARM63 (M1 Silicone)

Open lterfloth opened this issue 3 years ago • 5 comments

When I try to compile a python project that uses tkinterdnd2 I get the following message:

Traceback (most recent call last):
  File "/opt/homebrew/lib/python3.9/site-packages/tkinterdnd2/TkinterDnD.py", line 53, in _require
    TkdndVersion = tkroot.tk.call('package', 'require', 'tkdnd')
_tkinter.TclError: dlopen(/opt/homebrew/lib/python3.9/site-packages/tkinterdnd2/tkdnd/osx64/libtkdnd2.9.2.dylib, 0x0006): tried: '/opt/homebrew/lib/python3.9/site-packages/tkinterdnd2/tkdnd/osx64/libtkdnd2.9.2.dylib' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64e'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Downloads/elan2maxqda-main/main.py", line 15, in <module>
    root = TkinterDnD.Tk()
  File "/opt/homebrew/lib/python3.9/site-packages/tkinterdnd2/TkinterDnD.py", line 285, in __init__
    self.TkdndVersion = _require(self)
  File "/opt/homebrew/lib/python3.9/site-packages/tkinterdnd2/TkinterDnD.py", line 55, in _require
    raise RuntimeError('Unable to load tkdnd library.')
RuntimeError: Unable to load tkdnd library.

lterfloth avatar Jun 15 '22 08:06 lterfloth

same issue, cant compile an arm64 version

ghost avatar Aug 12 '22 07:08 ghost

One good person compiled the library. Thank him very much. https://github.com/blacklein/tkinterdnd2-osxarm64

v0hmly avatar Mar 23 '23 15:03 v0hmly

@v0hm I have uploaded a universal version of tkinterdnd2 to pypi. To install it, I suggest using "pip install tkinterdnd2-universal". If you plan on using pyinstaller, please use the hook file provided in the repository. https://github.com/blacklein/tkinterdnd2-universal

ghost avatar Mar 23 '23 15:03 ghost

He seems to have deleted his GitHub account but you can still get it via: pip install tkinterdnd2-universal

DalbyTech avatar Sep 08 '23 17:09 DalbyTech

Mentioning here for the citizens of the future: the tkinterdnd2-universal repository will stop working with python 3.13; however, I've started maintaining https://github.com/Eliav2/tkinterdnd2 which is the package you download with pip install tkinterdnd2. I am also including the ARM binaries now. If you have any problems feel free to create an issue on that package.

Squiblydoo avatar Aug 25 '24 19:08 Squiblydoo