From f5cf2e899b64cd794be6c2420ac39c64a4068030 Mon Sep 17 00:00:00 2001
From: Simon McVittie <smcv@collabora.com>
Date: Thu, 19 Nov 2020 13:09:23 +0000
Subject: [PATCH] debian: Allow building with only libcapsule-tools-relocatable
 installed

The Steam Runtime 2 'soldier' SDK only includes the relocatable version,
and there's no real reason why we can't accept either.

Signed-off-by: Simon McVittie <smcv@collabora.com>
---
 debian/control | 2 +-
 debian/rules   | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/debian/control b/debian/control
index d04e547b3..4ce5d1819 100644
--- a/debian/control
+++ b/debian/control
@@ -9,7 +9,7 @@ Build-Depends:
  gcc (>= 4:4.8) | gcc-4.8,
  glslang-tools,
  gtk-doc-tools <!nodoc>,
- libcapsule-tools,
+ libcapsule-tools | libcapsule-tools-relocatable,
  libelf-dev,
  libgl1-mesa-dev | libgl-dev,
  libglib2.0-dev,
diff --git a/debian/rules b/debian/rules
index 4d18e1f9b..40489f926 100755
--- a/debian/rules
+++ b/debian/rules
@@ -110,6 +110,7 @@ override_dh_link:
 	:
 	install -d $(relocatable_pkglibdir)
 	ln -fnsv ../libsteam-runtime-tools-0.so.0 $(relocatable_pkglibdir)
+	export PATH=/usr/lib/libcapsule/relocatable:$$PATH; \
 	LD_LIBRARY_PATH='$(DESTDIR)/usr/$(libdir)' \
 	$(DEB_HOST_MULTIARCH)-capsule-capture-libs \
 		--container / \
-- 
GitLab