MINGW-packages: Python GLib on CLANG64: `Failed to load shared library 'OVERVIEW: llvm-dlltool'`
When importing GLib with Pyhton 3 the library is not found. This issue is only present in CLANG64. MINGW64 works fine.
To repro:
Install mingw-w64-clang-x86_64-python-gobject
and run:
import sys
from gi.repository import GLib
sys.exit()
An exception occurs:
$ python ./clang_gi.py
** (process:15656): WARNING **: 01:06:00.183: Failed to load shared library 'OVERVIEW: llvm-dlltool' referenced by the typelib: 'OVERVIEW: llvm-dlltool.dll': The specified module could not be found.
** (process:15656): WARNING **: 01:06:00.183: Failed to load shared library 'OVERVIEW: llvm-dlltool' referenced by the typelib: 'OVERVIEW: llvm-dlltool.dll': The specified module could not be found.
Traceback (most recent call last):
File "D:\Temp\clang_gi\clang_gi.py", line 3, in <module>
from gi.repository import GLib
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 672, in _load_unlocked
File "<frozen importlib._bootstrap>", line 632, in _load_backward_compatible
File "D:/msys64/clang64/lib/python3.10/site-packages/gi/importer.py", line 150, in load_module
dynamic_module = load_overrides(introspection_module)
File "D:/msys64/clang64/lib/python3.10/site-packages/gi/overrides/__init__.py", line 118, in load_overrides
override_mod = importlib.import_module(override_package_name)
File "D:/msys64/clang64/lib/python3.10/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "D:/msys64/clang64/lib/python3.10/site-packages/gi/overrides/GLib.py", line 37, in <module>
from gi import _option as option
File "D:/msys64/clang64/lib/python3.10/site-packages/gi/_option.py", line 40, in <module>
OPTION_CONTEXT_ERROR_QUARK = GLib.quark_to_string(GLib.option_error_quark())
gi._error.GError: g-invoke-error-quark: Could not locate g_option_error_quark: 'OVERVIEW: llvm-dlltool.dll': The specified module could not be found. (1)
I don’t know python, and even less GLib 😦 mingw-w64-clang-x86_64-python: 3.10.5-2 mingw-w64-clang-x86_64-python-gobject: 3.42.1-3
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Reactions: 1
- Comments: 15 (15 by maintainers)
Commits related to this issue
- gobject-introspection: fix gir/typelib generation with llvm/clang g-i tries to lookup the DLL name based on the import lib but failed to do so with clang. llvm-dlltool doesn't have an "--identify" op... — committed to lazka/MINGW-packages by lazka 2 years ago
- gobject-introspection: fix gir/typelib generation with llvm/clang g-i tries to lookup the DLL name based on the import lib but failed to do so with clang. llvm-dlltool doesn't have an "--identify" op... — committed to lazka/MINGW-packages by lazka 2 years ago
- Some rebuilds for g-i clang fixes see #11994 — committed to msys2/MINGW-packages by lazka 2 years ago
- More g-i related rebuilds see #11994 — committed to msys2/MINGW-packages by lazka 2 years ago
We have a Python crasher right now that makes everything complicated in CI. I’ll handle the rebuilds…
Upstream PR: https://gitlab.gnome.org/GNOME/gobject-introspection/-/merge_requests/349
I’ll have a look next week, if that helps…