File 0001-build-disable-unloading-of-libtss2-tcti-tabrmd.so.patch of Package tpm2.0-abrmd.14624

From d3f699d828616280c1245ced1ab6a43baca6e63f Mon Sep 17 00:00:00 2001
From: Jonas Witschel <diabonas@gmx.de>
Date: Tue, 1 Jan 2019 01:11:16 +0100
Subject: [PATCH] build: disable unloading of libtss2-tcti-tabrmd.so

If the dynamic library is unloaded with dlclose(), it cannot be
loaded with dlopen() again, it will segfault with a "cannot register
existing type" GLib error.

Fixes #545.

Signed-off-by: Jonas Witschel <diabonas@gmx.de>
---
 Makefile.am | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Index: tpm2-abrmd-2.0.2/Makefile.am
===================================================================
--- tpm2-abrmd-2.0.2.orig/Makefile.am
+++ tpm2-abrmd-2.0.2/Makefile.am
@@ -254,7 +254,7 @@ test_integration_libtest_la_SOURCES = \
 
 src_libtss2_tcti_tabrmd_la_LIBADD   = $(DBUS_LIBS) $(GIO_LIBS) $(GLIB_LIBS) \
     $(PTHREAD_LIBS) $(noinst_LTLIBRARIES) $(TSS2_SYS_LIBS)
-src_libtss2_tcti_tabrmd_la_LDFLAGS = -fPIC -Wl,--no-undefined -Wl,--version-script=$(srcdir)/src/tcti-tabrmd.map
+src_libtss2_tcti_tabrmd_la_LDFLAGS = -fPIC -Wl,--no-undefined -Wl,-z,nodelete -Wl,--version-script=$(srcdir)/src/tcti-tabrmd.map
 src_libtss2_tcti_tabrmd_la_SOURCES = src/tcti-tabrmd.c src/tcti-tabrmd-priv.h $(srcdir)/src/tcti-tabrmd.map
 
 src_libtss2_tcti_echo_la_LIBADD  = $(DBUS_LIBS) $(GLIB_LIBS)
openSUSE Build Service is sponsored by