Package: libssl-dev
Version: 3.0.0~~alpha4-1
Severity: normal
Tags: patch

Trying to install both libssl-dev and libssl:arm64 fails because
/usr/include/openssl/configuration.h is architecture-specific.

----------------8<----------------8<----------------8<-----------------<
Selecting previously unselected package libssl-dev:arm64.
Preparing to unpack .../26-libssl-dev_3.0.0~~alpha4-1_arm64.deb ...
Unpacking libssl-dev:arm64 (3.0.0~~alpha4-1) ...
dpkg: error processing archive 
/tmp/apt-dpkg-install-oaoCmE/26-libssl-dev_3.0.0~~alpha4-1_arm64.deb (--unp
ack):
 trying to overwrite shared '/usr/include/openssl/configuration.h', which is 
different from other instance
s of package libssl-dev:arm64
dpkg-deb: error: paste subprocess was killed by signal (Broken pipe)
Errors were encountered while processing:
 /tmp/apt-dpkg-install-oaoCmE/26-libssl-dev_3.0.0~~alpha4-1_arm64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
----------------8<----------------8<----------------8<-----------------

The attached patch fixes it by handling the new openssl/configuration.h
header file in the same as the existing openssl/opensslconf.h.
From aa76e278757aba94cc1e81ccc40970bf9cf68631 Mon Sep 17 00:00:00 2001
From: Antonio Terceiro <terce...@debian.org>
Date: Fri, 19 Mar 2021 17:23:07 -0300
Subject: [PATCH] debian/rules: install openssl/configuration.h to multiarch
 dir

This makes a foreign libssl-dev coinstallable with it's native
counterpart.
---
 debian/rules | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/debian/rules b/debian/rules
index 9d924f21bf..24fd65ea0c 100755
--- a/debian/rules
+++ b/debian/rules
@@ -107,6 +107,7 @@ override_dh_auto_install-indep:
 		$(MAKE) -C build_shared install DESTDIR=`pwd`/debian/tmp ;\
 		mkdir -p debian/tmp/usr/include/$(DEB_HOST_MULTIARCH)/openssl ;\
 		mv debian/tmp/usr/include/openssl/opensslconf.h debian/tmp/usr/include/$(DEB_HOST_MULTIARCH)/openssl/ ;\
+		mv debian/tmp/usr/include/openssl/configuration.h debian/tmp/usr/include/$(DEB_HOST_MULTIARCH)/openssl/ ;\
 	fi
 
 override_dh_auto_install-arch:
@@ -129,6 +130,7 @@ override_dh_auto_install-arch:
 	done
 	mkdir -p debian/tmp/usr/include/$(DEB_HOST_MULTIARCH)/openssl
 	mv debian/tmp/usr/include/openssl/opensslconf.h debian/tmp/usr/include/$(DEB_HOST_MULTIARCH)/openssl/
+	mv debian/tmp/usr/include/openssl/configuration.h debian/tmp/usr/include/$(DEB_HOST_MULTIARCH)/openssl/
 
 override_dh_installchangelogs:
 	dh_installchangelogs CHANGES.md
-- 
2.30.2

Attachment: signature.asc
Description: PGP signature

Reply via email to