mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
* [ptxdist] [PATCH] tpm2-tss: Fix conflict with SYSTEMD_UDEV_CUST_RULES
@ 2022-06-27 12:06 Thorsten Scherer
  2022-07-01  5:38 ` Michael Olbrich
  0 siblings, 1 reply; 2+ messages in thread
From: Thorsten Scherer @ 2022-06-27 12:06 UTC (permalink / raw)
  To: ptxdist; +Cc: Thorsten Scherer, mkl

The target root.tgz fails with:

 * check_data_file_clashes: Package systemd wants to install file
   <BSP-PATH>/platform-<XYZ>/build-target/image-root-tgz/usr/lib/udev/rules.d/70-tpm-udev.rules
        But that file is already provided by package  * tpm2-tss

Add a check to avoid conflicts.

Signed-off-by: Thorsten Scherer <t.scherer@eckelmann.de>
---
 rules/tpm2-tss.in   | 12 ++++++++++++
 rules/tpm2-tss.make |  2 ++
 2 files changed, 14 insertions(+)

diff --git a/rules/tpm2-tss.in b/rules/tpm2-tss.in
index 75d32188c..8eeb4b5c7 100644
--- a/rules/tpm2-tss.in
+++ b/rules/tpm2-tss.in
@@ -22,3 +22,15 @@ config TPM2_TSS
 	  This package contains the TSS and TCTI libraries that client
 	  applications will link against when they require accessing
 	  the TPM.
+
+if TPM2_TSS
+
+comment "tpm2-tss install udev rules conflicts SYSTEMD_UDEV_CUST_RULES"
+	depends on SYSTEMD_UDEV_CUST_RULES
+
+config TPM2_TSS_INSTALL_UDEV_RULES
+	bool
+	prompt "tpm2-tss install udev rules"
+	depends on !SYSTEMD_UDEV_CUST_RULES
+
+endif
diff --git a/rules/tpm2-tss.make b/rules/tpm2-tss.make
index 7e0b4ff52..8c948a57a 100644
--- a/rules/tpm2-tss.make
+++ b/rules/tpm2-tss.make
@@ -92,8 +92,10 @@ $(STATEDIR)/tpm2-tss.targetinstall:
 	@$(call install_lib, tpm2-tss, 0, 0, 0644, libtss2-tctildr)
 	@$(call install_lib, tpm2-tss, 0, 0, 0644, libtss2-rc)
 
+ifdef TPM2_TSS_INSTALL_UDEV_RULES
 	@$(call install_alternative, tpm2-tss, 0, 0, 0644, \
 		/usr/lib/udev/rules.d/70-tpm-udev.rules)
+endif
 
 	@$(call install_finish, tpm2-tss)
 
-- 
2.30.2




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-07-01  5:38 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-27 12:06 [ptxdist] [PATCH] tpm2-tss: Fix conflict with SYSTEMD_UDEV_CUST_RULES Thorsten Scherer
2022-07-01  5:38 ` Michael Olbrich

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox