Your message dated Sun, 06 Oct 2019 21:59:00 +0000
with message-id <[email protected]>
and subject line Bug#940173: fixed in mmdebstrap 0.5.0-1
has caused the Debian Bug report #940173,
regarding mmdebstrap hooks should be able to remove start-stop-daemon
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
940173: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=940173
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: mmdebstrap
Version: 0.4.1-6
Severity: minor
Tags: patch

Hi josch,

I ran into another minor problem with the (unofficial) hooks. If a
--customize-hook removes /sbin/start-stop-daemon.REAL, mmdebstrap fails.
Can we make it cope with that situation? I'm attaching some patches for
you.

Helmut
>From 7c53a346c2c20e5dbff6b30c2a7f7acc6dd280ec Mon Sep 17 00:00:00 2001
From: Helmut Grohne <[email protected]>
Date: Fri, 13 Sep 2019 12:36:02 +0200
Subject: [PATCH 1/3] fix error message about opening s-s-d

---
 mmdebstrap | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/mmdebstrap b/mmdebstrap
index 0fdd6ee..5c331aa 100755
--- a/mmdebstrap
+++ b/mmdebstrap
@@ -863,7 +863,7 @@ sub run_chroot(&$) {
 
 	{
 	    move("$options->{root}/sbin/start-stop-daemon", "$options->{root}/sbin/start-stop-daemon.REAL") or error "cannot move start-stop-daemon";
-	    open my $fh, '>', "$options->{root}/sbin/start-stop-daemon" or error "cannot open policy-rc.d: $!";
+	    open my $fh, '>', "$options->{root}/sbin/start-stop-daemon" or error "cannot open start-stop-daemon: $!";
 	    print $fh "#!/bin/sh\n";
 	    print $fh "echo \"Warning: Fake start-stop-daemon called, doing nothing\">&2\n";
 	    close $fh;
-- 
2.20.1

>From 00fd0dc4b31418754a43f4f0c082dc20615a5073 Mon Sep 17 00:00:00 2001
From: Helmut Grohne <[email protected]>
Date: Fri, 13 Sep 2019 12:36:59 +0200
Subject: [PATCH 2/3] make errors about moving s-s-d more verbose

---
 mmdebstrap | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/mmdebstrap b/mmdebstrap
index 5c331aa..cd9f96b 100755
--- a/mmdebstrap
+++ b/mmdebstrap
@@ -862,7 +862,7 @@ sub run_chroot(&$) {
 	}
 
 	{
-	    move("$options->{root}/sbin/start-stop-daemon", "$options->{root}/sbin/start-stop-daemon.REAL") or error "cannot move start-stop-daemon";
+	    move("$options->{root}/sbin/start-stop-daemon", "$options->{root}/sbin/start-stop-daemon.REAL") or error "cannot move start-stop-daemon: $!";
 	    open my $fh, '>', "$options->{root}/sbin/start-stop-daemon" or error "cannot open start-stop-daemon: $!";
 	    print $fh "#!/bin/sh\n";
 	    print $fh "echo \"Warning: Fake start-stop-daemon called, doing nothing\">&2\n";
@@ -873,7 +873,7 @@ sub run_chroot(&$) {
 	&{$cmd}();
 
 	# cleanup
-	move("$options->{root}/sbin/start-stop-daemon.REAL", "$options->{root}/sbin/start-stop-daemon") or error "cannot move start-stop-daemon";
+	move("$options->{root}/sbin/start-stop-daemon.REAL", "$options->{root}/sbin/start-stop-daemon") or error "cannot move start-stop-daemon: $!";
 	unlink "$options->{root}/usr/sbin/policy-rc.d" or error "cannot unlink policy-rc.d: $!";
 
     };
-- 
2.20.1

>From 8033519aa0de689f579fe59d4b1142e87c11bdc8 Mon Sep 17 00:00:00 2001
From: Helmut Grohne <[email protected]>
Date: Fri, 13 Sep 2019 12:37:28 +0200
Subject: [PATCH 3/3] allow messing with s-s-d in hooks

Presently, mmdebstrap fails hard if e.g. a --setup-hook removes
start-stop-daemon.REAL.
---
 mmdebstrap | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/mmdebstrap b/mmdebstrap
index cd9f96b..f3a64ba 100755
--- a/mmdebstrap
+++ b/mmdebstrap
@@ -861,7 +861,7 @@ sub run_chroot(&$) {
 	    chmod 0755, "$options->{root}/usr/sbin/policy-rc.d" or error "cannot chmod policy-rc.d: $!";
 	}
 
-	{
+	if (-e "$options->{root}/sbin/start-stop-daemon") {
 	    move("$options->{root}/sbin/start-stop-daemon", "$options->{root}/sbin/start-stop-daemon.REAL") or error "cannot move start-stop-daemon: $!";
 	    open my $fh, '>', "$options->{root}/sbin/start-stop-daemon" or error "cannot open start-stop-daemon: $!";
 	    print $fh "#!/bin/sh\n";
@@ -873,7 +873,9 @@ sub run_chroot(&$) {
 	&{$cmd}();
 
 	# cleanup
-	move("$options->{root}/sbin/start-stop-daemon.REAL", "$options->{root}/sbin/start-stop-daemon") or error "cannot move start-stop-daemon: $!";
+	if (-e "$options->{root}/sbin/start-stop-daemon.REAL") {
+	    move("$options->{root}/sbin/start-stop-daemon.REAL", "$options->{root}/sbin/start-stop-daemon") or error "cannot move start-stop-daemon: $!";
+	}
 	unlink "$options->{root}/usr/sbin/policy-rc.d" or error "cannot unlink policy-rc.d: $!";
 
     };
-- 
2.20.1


--- End Message ---
--- Begin Message ---
Source: mmdebstrap
Source-Version: 0.5.0-1

We believe that the bug you reported is fixed in the latest version of
mmdebstrap, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Johannes 'josch' Schauer <[email protected]> (supplier of updated mmdebstrap 
package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Sun, 06 Oct 2019 23:20:58 +0200
Source: mmdebstrap
Binary: mmdebstrap
Architecture: source
Version: 0.5.0-1
Distribution: unstable
Urgency: medium
Maintainer: Johannes 'josch' Schauer <[email protected]>
Changed-By: Johannes 'josch' Schauer <[email protected]>
Description:
 mmdebstrap - create a Debian chroot
Closes: 934199 935258 935260 935266 940162 940173
Changes:
 mmdebstrap (0.5.0-1) unstable; urgency=medium
 .
   * new upstream release
      - rework CLI interface to use explicit "-" for stdin where ambiguous
        instead of unconditionally reading stdin (closes: #934199)
      - also create /var/lib/dpkg/arch in chrootless mode (closes: #935258)
      - don't cleanup qemu-user in chrootless mode (closes: #935260)
      - allow hooks to remove start-stop-daemon (closes: #940173)
      - fix tarball permissions in chrootless mode (closes: #935266)
      - only report binfmt_misc errors if needed (closes: #940162)
   * run testsuite with distribution of the autopkgtest environment
   * drop patches that were applied upstream
   * apply two new patches to accommodate for salsa CI
Checksums-Sha1:
 57868dea3a9ab702b691e745588823361df30d34 2205 mmdebstrap_0.5.0-1.dsc
 e239c33923b2b83d77fa88e010fbec5940f2e5ab 47650 mmdebstrap_0.5.0.orig.tar.gz
 42f584e5db7eab2b130ad6eb344e019a1b874465 6944 mmdebstrap_0.5.0-1.debian.tar.xz
Checksums-Sha256:
 948fade15595be9b8ae99580fbd674d5c146ee7d2059461ef725b97c05397e25 2205 
mmdebstrap_0.5.0-1.dsc
 036b439f767d2c2cee7eaf2034676592dfb48712d8c55dbc63d6977ec95abde5 47650 
mmdebstrap_0.5.0.orig.tar.gz
 b3ff2454adef3d7ca1649285ad0d4071cf170db47a764cadb083ebdf115107db 6944 
mmdebstrap_0.5.0-1.debian.tar.xz
Files:
 5b9a10359bf4f92b935b40c66de83af7 2205 admin optional mmdebstrap_0.5.0-1.dsc
 24947ab3de56c386eef1723d5525a164 47650 admin optional 
mmdebstrap_0.5.0.orig.tar.gz
 35418af3731dba88fd9454b99582242d 6944 admin optional 
mmdebstrap_0.5.0-1.debian.tar.xz

-----BEGIN PGP SIGNATURE-----

iQIzBAEBCAAdFiEElFhU6KL81LF4wVq58sulx4+9g+EFAl2aW18ACgkQ8sulx4+9
g+Fqaw/+OM1VDcU8yvcIglbm1056wAs3SWxXCEbCxgTdmkEl2LbNOlbMv8Xe7oXA
DmjlDDWYC3BPl280wDuFqN6hXg1OktlGloEu7aP9eoS8EKbnHIT64Izj9JdkRnXe
duEafWzERN6qruT0gHULuXLBPXeJOcQdmwtrvhmM17z3ILWsRYsbe0stWR0UEWD7
etBGtYRK4lVFja70mCvKshZ3T7uD3kjILeKXReuDl7+XW3HRzU/2du+xQskZ8f83
G6FSFM0YEJwbiJ/Ei8dtCJBPAqq4I3nWs/vRhHsjMkNjgz7WUXMmUwL5lVlGaGRb
aFQeIJmpol6HwloeeDRFxS7ZUS+kfmS5dWcYM2bTRktye3mpW+NOUxtDgeCXY4rq
ld9Pw9VKC7BGPRNmNm/GTadBbEeXVAPtBStjV0Y4KJoUYSzgrW2zF87PIYZ7V4s4
OK8MHqfNBFg2RKQwRRmCJnr6YweY4vEkALubtijliT+eMiTJZViqMvccgSNkG+cX
dvV9kdYd5nsA+toxiHYLfVwswJnJgqLBQ2Yj91tT+eTWBIKEoKPCBsBxqBWid3wr
j5zMNkff6hzV/4Th8hbNlzfiZGsXAwjvypuPVCBcv5CSw8P7NnSChOPo8VtElYeF
Spf5ei1HxMvRxO/SPNk7RloD5+93S+93yVLrIEgfzxY4kPy3qlA=
=N5dF
-----END PGP SIGNATURE-----

--- End Message ---

Reply via email to