Bug#981422: xdg-utils: autopkgtest failure: make: dh: No such file or directory
Source: xdg-utils Followup-For: Bug #981422 Hello The attached commit suggests a third option. If you call the scripts with an explicit interpreter, they need no execution rights in the first place. >From 5a48d85ad66d60e9be0085e98fdc6ab830cf2e9f Mon Sep 17 00:00:00 2001 From: Nicolas Boulenguez Date: Wed, 31 Mar 2021 17:05:29 +0200 Subject: autotests: in test-lib.sh, call tty{on,off} with an explicit interpreter Explicit interpreters are usually discouraged so the calling code is not broken by changes in the implementation, but in this case, autotests/tty{on,off} are private helpers for autotests/test-lib.sh. With an explicit interpreter, the scripts do not need execution rights. Closes: #981422. diff --git a/autotests/test-lib.sh b/autotests/test-lib.sh index 87cab44..a16eb93 100644 --- a/autotests/test-lib.sh +++ b/autotests/test-lib.sh @@ -200,9 +200,9 @@ run() { local trace= if [ "$DETACH" = 0 ]; then -trace="./ttyon" +trace="/usr/bin/perl ttyon" elif [ "$DETACH" = 1 ]; then -trace="./ttyoff" +trace="/usr/bin/perl ttyoff" fi trace="$trace ${SHELL:-/bin/sh}" if [ "$TRACE" = 1 ]; then diff --git a/autotests/ttyoff b/autotests/ttyoff old mode 100755 new mode 100644 diff --git a/autotests/ttyon b/autotests/ttyon old mode 100755 new mode 100644 diff --git a/debian/rules b/debian/rules index 50c1d53..59b7c05 100755 --- a/debian/rules +++ b/debian/rules @@ -26,8 +26,6 @@ override_dh_auto_clean: override_dh_auto_test: ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS))) -# Fix perms of new files from the patch. - chmod +x autotests/ttyon autotests/ttyoff # Use automated tests that do not require a user action. make autotest endif diff --git a/debian/tests/entry b/debian/tests/entry index 4c1e834..7ba19b7 100755 --- a/debian/tests/entry +++ b/debian/tests/entry @@ -13,6 +13,5 @@ fi BASH_XTRACEFD=1 set -x -debian/rules patch ./configure make autotest SHELL="${1:-/bin/sh}"
Bug#981422: xdg-utils: autopkgtest failure: make: dh: No such file or directory
On Mon, 2021-03-01 at 10:40 +0100, Emilio Pozuelo Monfort wrote: > You can ship the files directly in the debian.tar by adding them to > debian/source/include-binaries, and that way you don't need to call chmod as > their mode will be preserved. That would probably help with this autopkgtest > patch issue. Unfortunately, dpkg does not see these new files because it first applies an autogenerated patch. At least, .debian.tar.xz archive has no files I mentioned in the include-binaries list. https://salsa.debian.org/freedesktop-team/xdg-utils/-/pipelines/235570 On Sun, 2021-02-28 at 10:20 -0300, Antonio Terceiro wrote: > Please drop patching from the test entirely. autopkgtests are supposed > to _start_ running against a fully patched source tree. autopkgtest(1) > does this automatically. > > I understand that this might be convenient when working on the package, > but please automate it in a way that it's not also done when running the > autopkgtest "for real". Any ideas how to preserve executable bit of new files in other way? For now, I see only one option: manually chmod +x either by the debian/rules patch target or repeated for dh_auto_test and in the autopkgtest runner. signature.asc Description: This is a digitally signed message part
Bug#981422: xdg-utils: autopkgtest failure: make: dh: No such file or directory
On 30/01/2021 22:22, Nicholas Guriev wrote: Hello! On Sat, 2021-01-30 at 21:54 +0100, Paul Gevers wrote: You recently added an autopkgtest to your package xdg-utils, great. However, it fails. Currently this failure is blocking the migration to testing [1]. Can you please investigate the situation and fix it? There are several ways to fix the failure. 1. Replace `debian/rules patch` line in a test script with `chmod +x autotests/tty{on,off}`. --- a/debian/tests/entry +++ b/debian/tests/entry @@ -13,6 +13,6 @@ fi BASH_XTRACEFD=1 set -x · -debian/rules patch ./configure +chmod +x autotests/tty{on,off} make autotest SHELL="${1:-/bin/sh}" https://salsa.debian.org/freedesktop-team/xdg-utils/-/commit/9928933504932f19fb39a0f671cdc7be78aada29 2. Put the "patch" target back as it was in -3 revision, and fix arch- independent build. https://salsa.debian.org/freedesktop-team/xdg-utils/-/merge_requests/4/diffs?commit_id=0617f9284ae4d79b51c4ad4bc7d781e93561cb23 I still prefer the later option with the "patch" target. Because that chmod fixes flaws of quilt and dpkg and this solutions is more universal. I hope someone will choose to upload another one-liner fix. You can ship the files directly in the debian.tar by adding them to debian/source/include-binaries, and that way you don't need to call chmod as their mode will be preserved. That would probably help with this autopkgtest patch issue. Cheers, Emilio
Bug#981422: xdg-utils: autopkgtest failure: make: dh: No such file or directory
On Sun, 31 Jan 2021 00:22:25 +0300 Nicholas Guriev wrote: > Hello! > > On Sat, 2021-01-30 at 21:54 +0100, Paul Gevers wrote: > > You recently added an autopkgtest to your package xdg-utils, great. > > However, it fails. Currently this failure is blocking the migration to > > testing [1]. Can you please investigate the situation and fix it? > > There are several ways to fix the failure. > > 1. Replace `debian/rules patch` line in a test script with `chmod +x > autotests/tty{on,off}`. > > --- a/debian/tests/entry > +++ b/debian/tests/entry > @@ -13,6 +13,6 @@ fi > BASH_XTRACEFD=1 > set -x > · > -debian/rules patch > ./configure > +chmod +x autotests/tty{on,off} > make autotest SHELL="${1:-/bin/sh}" > > https://salsa.debian.org/freedesktop-team/xdg-utils/-/commit/9928933504932f19fb39a0f671cdc7be78aada29 > > 2. Put the "patch" target back as it was in -3 revision, and fix arch- > independent build. > > https://salsa.debian.org/freedesktop-team/xdg-utils/-/merge_requests/4/diffs?commit_id=0617f9284ae4d79b51c4ad4bc7d781e93561cb23 > > I still prefer the later option with the "patch" target. Because that > chmod fixes flaws of quilt and dpkg and this solutions is more > universal. I hope someone will choose to upload another one-liner fix. Please drop patching from the test entirely. autopkgtests are supposed to _start_ running against a fully patched source tree. autopkgtest(1) does this automatically. I understand that this might be convenient when working on the package, but please automate it in a way that it's not also done when running the autopkgtest "for real". signature.asc Description: PGP signature
Bug#981422: xdg-utils: autopkgtest failure: make: dh: No such file or directory
Hello! On Sat, 2021-01-30 at 21:54 +0100, Paul Gevers wrote: > You recently added an autopkgtest to your package xdg-utils, great. > However, it fails. Currently this failure is blocking the migration to > testing [1]. Can you please investigate the situation and fix it? There are several ways to fix the failure. 1. Replace `debian/rules patch` line in a test script with `chmod +x autotests/tty{on,off}`. --- a/debian/tests/entry +++ b/debian/tests/entry @@ -13,6 +13,6 @@ fi BASH_XTRACEFD=1 set -x · -debian/rules patch ./configure +chmod +x autotests/tty{on,off} make autotest SHELL="${1:-/bin/sh}" https://salsa.debian.org/freedesktop-team/xdg-utils/-/commit/9928933504932f19fb39a0f671cdc7be78aada29 2. Put the "patch" target back as it was in -3 revision, and fix arch- independent build. https://salsa.debian.org/freedesktop-team/xdg-utils/-/merge_requests/4/diffs?commit_id=0617f9284ae4d79b51c4ad4bc7d781e93561cb23 I still prefer the later option with the "patch" target. Because that chmod fixes flaws of quilt and dpkg and this solutions is more universal. I hope someone will choose to upload another one-liner fix. signature.asc Description: This is a digitally signed message part
Bug#981422: xdg-utils: autopkgtest failure: make: dh: No such file or directory
Source: xdg-utils Version: 1.1.3-4 X-Debbugs-CC: debian...@lists.debian.org Severity: serious User: debian...@lists.debian.org Usertags: fails-always Dear maintainer(s), You recently added an autopkgtest to your package xdg-utils, great. However, it fails. Currently this failure is blocking the migration to testing [1]. Can you please investigate the situation and fix it? I copied some of the output at the bottom of this report. Seems like your missing test dependencies. More information about this bug and the reason for filing it can be found on https://wiki.debian.org/ContinuousIntegration/RegressionEmailInformation Paul [1] https://qa.debian.org/excuses.php?package=xdg-utils https://ci.debian.net/data/autopkgtest/testing/amd64/x/xdg-utils/9808301/log.gz autopkgtest [01:30:39]: test with-bash: [--- + debian/rules patch dh patch make: dh: No such file or directory make: *** [debian/rules:6: patch] Error 127 autopkgtest [01:30:39]: test with-bash: ---] autopkgtest [01:30:44]: test with-dash: [--- + debian/rules patch dh patch make: dh: No such file or directory make: *** [debian/rules:6: patch] Error 127 autopkgtest [01:30:44]: test with-dash: ---] OpenPGP_signature Description: OpenPGP digital signature