Hi doko, Quoting Johannes Schauer Marin Rodrigues (2022-08-28 08:28:52) > On Wed, 17 Aug 2022 18:20:36 +0200 Johannes Schauer Marin Rodrigues > <jo...@debian.org> wrote: > > On Wed, 16 Mar 2022 13:30:26 +0100 Johannes Schauer Marin Rodrigues > > <jo...@debian.org> wrote: > > > when creating chroots for new architectures that are in the process of > > > being > > > bootstrapped without yet having emulation support from qemu, it is not > > > possible to run maintainer scripts inside the foreign architecture chroot > > > because foreign architecture ELF binaries cannot be executed. The > > > solution to > > > that problem is to run maintainer scripts from outside the chroot and use > > > the > > > DPKG_ROOT environment variable to instruct the maintainer script on which > > > chroot to operate. By default, for normal installations, that environment > > > variable is set, but empty. > > > > > > Apart from init-system-helpers and pam, all packages in the > > > Essential:yes set have support for DPKG_ROOT already. To start building > > > packages we also need to install build-essential. > > > > > > Please consider applying the patch from this merge request: > > > > > > https://salsa.debian.org/toolchain-team/gcc-defaults/-/merge_requests/4 > > > > > > We tested it in our CI environment and it produces a bit-by-bit > > > identical chroot with DPKG_ROOT compared to a normal installation. > > > > > > https://salsa.debian.org/helmutg/dpkg-root-demo/ > > > > > > Since the DPKG_ROOT variable is empty on normal installations, the patch > > > should have no effect in the normal case. > > > > I wanted to send a friendly ping about this bug. I see that since I filed > > this > > bug, you uploaded three new versions of gcc-defaults. Please consider > > applying > > the changes of above merge request against gcc-defaults on salsa. Here is > > the > > diff in plain text for your convenience: > > > > --- a/debian/g++.postinst.in > > +++ b/debian/g++.postinst.in > > @@ -2,9 +2,9 @@ > > > > # remove the doc dir, if it's still a directory and replace with a symlink > > pkg=`basename $0 .postinst` > > -if [ ! -L /usr/share/doc/$pkg ]; then > > - rm -rf /usr/share/doc/$pkg > > - ln -s cpp /usr/share/doc/$pkg > > +if [ ! -L "$DPKG_ROOT/usr/share/doc/$pkg" ]; then > > + rm -rf "$DPKG_ROOT/usr/share/doc/$pkg" > > + ln -s cpp "$DPKG_ROOT/usr/share/doc/$pkg" > > fi > > > > # fix for report #138038: remove old diversions > > I uploaded an NMU of gcc-defaults with the maximum delay of 15 days. Please > cancel if you disagree. Full debdiff attached.
my last NMU got cancelled because you uploaded a new version of gcc-defaults while my NMU was still waiting in the delayed queue. On September 1, you told me in #debian-devel that this bug is on your TODO list but now more than two months have passed without anything having happened. So I uploaded another NMU of gcc-defaults with the maximum delay of 15 days. Please cancel if you disagree. Full debdiff attached. Thanks! cheers, josch
diff -Nru gcc-defaults-1.201/debian/changelog gcc-defaults-1.201+nmu1/debian/changelog --- gcc-defaults-1.201/debian/changelog 2022-08-31 10:25:04.000000000 +0200 +++ gcc-defaults-1.201+nmu1/debian/changelog 2022-11-18 10:57:42.000000000 +0100 @@ -1,3 +1,10 @@ +gcc-defaults (1.201+nmu1) unstable; urgency=medium + + * Non-maintainer upload. + * Support DPKG_ROOT in g++ postinst (closes: #1007764) + + -- Johannes Schauer Marin Rodrigues <jo...@debian.org> Fri, 18 Nov 2022 10:57:42 +0100 + gcc-defaults (1.201) unstable; urgency=medium * Bump GCC 12 version to 12.2.0. diff -Nru gcc-defaults-1.201/debian/g++.postinst.in gcc-defaults-1.201+nmu1/debian/g++.postinst.in --- gcc-defaults-1.201/debian/g++.postinst.in 2020-11-17 19:53:07.000000000 +0100 +++ gcc-defaults-1.201+nmu1/debian/g++.postinst.in 2022-11-18 10:56:43.000000000 +0100 @@ -2,9 +2,9 @@ # remove the doc dir, if it's still a directory and replace with a symlink pkg=`basename $0 .postinst` -if [ ! -L /usr/share/doc/$pkg ]; then - rm -rf /usr/share/doc/$pkg - ln -s cpp /usr/share/doc/$pkg +if [ ! -L "$DPKG_ROOT/usr/share/doc/$pkg" ]; then + rm -rf "$DPKG_ROOT/usr/share/doc/$pkg" + ln -s cpp "$DPKG_ROOT/usr/share/doc/$pkg" fi # fix for report #138038: remove old diversions
signature.asc
Description: signature