fix(guile-gnutls): use static guile pkg-config libs for configure link checks

This commit is contained in:
vxtls 2026-03-05 10:16:26 -05:00
parent 451fdc63ca
commit 9205c2b1e4
2 changed files with 59 additions and 7 deletions

View file

@ -0,0 +1,28 @@
SPDX-License-Identifier: GPL-3.0-or-later
Keep the Guile extension model while avoiding a second libguile copy inside
the extension module.
When Guile itself is built without shared libguile, linking the extension
against libguile can embed another runtime copy and lead to crashes. Rely on
symbols from the hosting Guile process instead.
--- guile-gnutls-v5.0.1/guile/src/Makefile.am
+++ guile-gnutls-v5.0.1/guile/src/Makefile.am
@@ -40,14 +40,13 @@
# Use '-module' to build a "dlopenable module", in Libtool terms.
# Use '-undefined' to placate Libtool on Windows; see
# <https://lists.gnutls.org/pipermail/gnutls-devel/2014-December/007294.html>.
-guile_gnutls_v_2_la_LDFLAGS = -module -no-undefined
+guile_gnutls_v_2_la_LDFLAGS = -module
guile_gnutls_v_2_la_SOURCES = core.c errors.c utils.c
guile_gnutls_v_2_la_CFLAGS = \
$(AM_CFLAGS) $(GNULIB_CFLAGS) $(GUILE_CFLAGS) $(GNUTLS_CFLAGS)
guile_gnutls_v_2_la_LIBADD = \
- $(GNUTLS_LIBS) \
- $(GUILE_LDFLAGS)
+ $(GNUTLS_LIBS)
AM_CPPFLAGS = \
-I$(top_srcdir)/lib/includes \