--- gee/Makefile.am.orig	2021-11-30 05:03:36.000000000 -0800
+++ gee/Makefile.am	2022-05-21 15:58:10.000000000 -0700
@@ -163,8 +163,12 @@
 # This is what g-ir-scanner does.
 libgee_dlname = \
 	`$(SED) -nE "s/^dlname='([A-Za-z0-9.+-]+)'/\1/p" libgee-0.8.la`
+# Extract libdir from libgee-0.8.la
+libgee_libdir = \
+	`$(SED) -nE "s/^libdir='([A-Za-z0-9.+-/]+)'/\1/p" libgee-0.8.la`
+# Prepend libdir path to dlname to form typelib referenced shared library path
 INTROSPECTION_COMPILER_ARGS= \
-	-l $(libgee_dlname)
+	-l $(libgee_libdir)/$(libgee_dlname)
 Gee-0.8.gir: libgee_0_8_la_vala.stamp
 Gee-0.8.typelib: Gee-0.8.gir libgee-0.8.la
 
