severity 953533 normal thank On Tue, 10 Mar 2020 08:10:06 +0000 "Cirujano Cuesta, Silvano" <silvano.cirujano-cue...@siemens.com> wrote: > Package: opensc > Version: 0.20.0-3 > Severity: serious > Justification: fails to build from source (but built successfully in the past) > Tags: ftbfs > > Trying to build fails. I've tried following two ways. > > I've tried > apt-get source opensc ; debuild -b -uc -us > and > apt-get --build source opensc > > > The error message is: > > dh_install: warning: Cannot find (any matches for) > "debian/tmp/etc/bash_completion.d/*" > (tried in ., debian/tmp) > dh_install: warning: opensc missing files: > debian/tmp/etc/bash_completion.d/* > dh_install: error: missing files,aborting > make: *** [debian/rules:4: binary] Error 25
I can reproduce your problem using "debuild" in testing. But I can't reproduce it using "gbp buildpackage" and cowbuilder When the package is built with debuild I have: " OpenSC has been configured with the following options: [...] Bash completion: /usr/share/bash-completion/completions [...] " But when the package is built with gbp (or the Debian builders) I find: " OpenSC has been configured with the following options: [...] Bash completion: /etc/bash_completion.d [...] " The problem is this piece of code in configure.ac: if test "${completiondir}" = "detect"; then echo completion ${completiondir} PKG_CHECK_MODULES([BASH_COMPLETION], [bash-completion >= 2.0], [completiondir="`pkg-config --variable=completionsdir bash-completion`"], [completiondir="${sysconfdir}/bash_completion.d"]) fi If bash-completion package is installed then the scipt uses: $ pkg-config --variable=completionsdir bash-completion that returns: /usr/share/bash-completion/completions But if bash-completion is NOT installed then ${sysconfdir}/bash_completion.d i.e. /etc/bash_completion.d is used instead. If you remove the package bash-completion then the build will succeed. I changed the priority of this bug since it fails to build only in some cases. I wanted to push my patch to https://salsa.debian.org/opensc-team/opensc but I am not a member of the "opensc-team" group on Salsa. https://salsa.debian.org/opensc-team My patch is attached so Eric can apply it.
>From ee128132d5ea8644151d7aa180fe580847de3c28 Mon Sep 17 00:00:00 2001 From: Ludovic Rousseau <ludovic.rouss...@free.fr> Date: Sat, 29 Aug 2020 22:26:24 +0200 Subject: [PATCH] Fix "Fails to build due to missing bash_completion files" Fix bash_completion path (Closes: #953533) --- debian/changelog | 9 +++++++++ debian/control | 3 ++- debian/opensc.install | 2 +- 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index 404cedf5..6b72f71e 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,12 @@ +opensc (0.20.0-3.1) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Fix "Fails to build due to missing bash_completion files" + Build-Depends: bash-completion so the correct path is found + (Closes: #953533) + + -- Ludovic Rousseau <rouss...@debian.org> Sat, 29 Aug 2020 22:25:43 +0200 + opensc (0.20.0-3) unstable; urgency=medium * Fix patch to use /etc/opensc for opensc.conf (Closes: 949229) diff --git a/debian/control b/debian/control index 374a55f2..03c11d73 100644 --- a/debian/control +++ b/debian/control @@ -3,7 +3,8 @@ Priority: optional Section: utils Maintainer: Debian OpenSC Maintainers <pkg-opensc-ma...@lists.alioth.debian.org> Uploaders: Eric Dorland <e...@debian.org> -Build-Depends: debhelper-compat (= 12), +Build-Depends: bash-completion, + debhelper-compat (= 12), docbook-xsl, flex, help2man, diff --git a/debian/opensc.install b/debian/opensc.install index 6213ab66..753806cb 100644 --- a/debian/opensc.install +++ b/debian/opensc.install @@ -1,5 +1,5 @@ debian/tmp/usr/bin/* -debian/tmp/etc/bash_completion.d/* usr/share/bash-completion/completions +debian/tmp/usr/share/bash-completion/completions debian/tmp/usr/share/man/man1/* debian/tmp/usr/share/man/man5/* -- 2.28.0