Skip to content

Introspection: Fix running g-ir-scanner 1.80.x+ on Windows

Chun-wei Fan requested to merge fix-introspection-windows into main

Hi,

This attempts to fix the introspection on Windows, on the GLib side, as now building introspection files for GLib is now done in GLib's build process, if the gobject-introspection tools is installed, especially on Python 3.8.x or later, where DLLs are only loaded by Python scripts only when they are in designated system paths or when they have been marked specifically using os.add_dll_directory(), so this update:

  • Ensures that the newly-build GLib DLLs are looked for first when loading the g-ir-* scripts that makes use of these DLLs.
  • Ensures that if there are no previous versions of GLib installed, the DLLs can always be loaded as we now look for the freshly-built ones first.

Related issues: #3296 and gobject-introspection#499 (closed).

With blessings, thank you!

Merge request reports