Debian Bug report logs -
#1035324
shaderc: reproducible-builds: Differences when /bin/sh -> bash
Reply or subscribe to this bug.
Toggle useless messages
Report forwarded
to debian-bugs-dist@lists.debian.org, reproducible-bugs@lists.alioth.debian.org, Philippe SWARTVAGHER <phil.swart@gmx.fr>:
Bug#1035324; Package src:shaderc.
(Sun, 30 Apr 2023 21:00:04 GMT) (full text, mbox, link).
Acknowledgement sent
to Vagrant Cascadian <vagrant@reproducible-builds.org>:
New Bug report received and forwarded. Copy sent to reproducible-bugs@lists.alioth.debian.org, Philippe SWARTVAGHER <phil.swart@gmx.fr>.
(Sun, 30 Apr 2023 21:00:04 GMT) (full text, mbox, link).
Message #5 received at submit@bugs.debian.org (full text, mbox, reply):
[Message part 1 (text/plain, inline)]
Source: shaderc
Severity: normal
Tags: patch
User: reproducible-builds@lists.alioth.debian.org
Usertags: shell
X-Debbugs-Cc: reproducible-bugs@lists.alioth.debian.org
When /bin/sh points to bash (instead of dash), the behavior of "echo"
differs in the rendering of "\n":
https://tests.reproducible-builds.org/debian/rb-pkg/unstable/amd64/diffoscope-results/shaderc.html
/usr/bin/glslc
shaderc·2023.2-1\nspirv-tools·2023.1-2
vs.
shaderc·2023.2-1
spirv-tools·2023.1-2
The attached patch to debian/rules fixes this by switching to use
printf, which appears to behave consistently regardless of the shell (at
least with my quick testing).
Thanks for maintaining shaderc!
live well,
vagrant
[0001-debian-rules-Use-printf-instead-of-echo-for-reproduc.patch (text/x-diff, inline)]
From 2cc141000791790054677b339e675c2cef150ac0 Mon Sep 17 00:00:00 2001
From: Vagrant Cascadian <vagrant@reproducible-builds.org>
Date: Sun, 30 Apr 2023 13:51:49 -0700
Subject: [PATCH] debian/rules: Use "printf" instead of "echo" for reproducible
builds.
The echo implementations of bash and dash may differ, using printf
works around this.
---
debian/rules | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/debian/rules b/debian/rules
index 4424963..5051e82 100755
--- a/debian/rules
+++ b/debian/rules
@@ -16,7 +16,7 @@ override_dh_auto_configure:
-DCMAKE_BUILD_RPATH_USE_ORIGIN=ON
override_dh_auto_build:
- echo "\"shaderc $(DEB_VERSION)\\\n\"" > obj-${DEB_HOST_GNU_TYPE}/build-version.inc
+ printf "\"shaderc $(DEB_VERSION)\\\n\"" > obj-${DEB_HOST_GNU_TYPE}/build-version.inc
dpkg-query -f '"spirv-tools $${Version}\\n"\n' -W spirv-tools >> obj-${DEB_HOST_GNU_TYPE}/build-version.inc
dpkg-query -f '"glslang $${Version}\\n"' -W glslang-dev >> obj-${DEB_HOST_GNU_TYPE}/build-version.inc
dh_auto_build
--
2.39.2
[signature.asc (application/pgp-signature, inline)]
Send a report that this bug log contains spam.
Debian bug tracking system administrator <owner@bugs.debian.org>.
Last modified:
Wed May 17 11:43:38 2023;
Machine Name:
bembo
Debian Bug tracking system
Debbugs is free software and licensed under the terms of the GNU
Public License version 2. The current version can be obtained
from https://bugs.debian.org/debbugs-source/.
Copyright © 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson,
2005-2017 Don Armstrong, and many other contributors.