[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#806936: marked as done (/usr/share/debootstrap/functions: use tar -h in extract_dpkg_deb_data)



Your message dated Wed, 19 Oct 2016 23:58:19 +0200
with message-id <87lgxkdmro.fsf@deep-thought.43-1.org>
and subject line Re: Bug#806936: /usr/share/debootstrap/functions: use tar -h in extract_dpkg_deb_data
has caused the Debian Bug report #806936,
regarding /usr/share/debootstrap/functions: use tar -h in extract_dpkg_deb_data
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 owner@bugs.debian.org
immediately.)


-- 
806936: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=806936
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Package: debootstrap
Version: 1.0.75
Severity: normal
File: /usr/share/debootstrap/functions

Hi,

dpkg behavior is to preserve as hard as it can the current layout of the
filesystem wrt. symlink to directories: it will try not to replace a
symlink by a folder or even the opposite.

In debootstrap early stages, dpkg is not used (because not yet installed
in the target), but a custom implementatin using dpkg-deb|tar or ar is
used. Unfortunately, this implementation doesn't follow dpkg behavior,
and will happily replace a symlink by a dir.

I'm using debootstrap in a custom way where I need to create some
symlinks beforehand (for example some multiarches dirs like lib -> lib64
in / and /usr), it works fine with dpkg, but not with debootstrap early
extract.

Would it be possible to replace the tar call in extract_dpkg_deb_data
with tar -hxf so it will follow symlinks instead of replacing them?

Regards,
-- 
Yves-Alexis


-- System Information:
Debian Release: stretch/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'testing'), (500, 'stable'), (500, 'oldstable'), (450, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.2.0-1-amd64 (SMP w/4 CPU cores)
Locale: LANG=fr_FR.utf8, LC_CTYPE=fr_FR.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages debootstrap depends on:
ii  wget  1.17-1

Versions of packages debootstrap recommends:
ii  debian-archive-keyring  2014.3
ii  gnupg                   1.4.19-6

debootstrap suggests no packages.

-- no debconf information

--- End Message ---
--- Begin Message ---
Version: 1.0.83

Yves-Alexis Perez writes:
> dpkg behavior is to preserve as hard as it can the current layout of the
> filesystem wrt. symlink to directories: it will try not to replace a
> symlink by a folder or even the opposite.
>
> In debootstrap early stages, dpkg is not used (because not yet installed
> in the target), but a custom implementatin using dpkg-deb|tar or ar is
> used. Unfortunately, this implementation doesn't follow dpkg behavior,
> and will happily replace a symlink by a dir.
>
> I'm using debootstrap in a custom way where I need to create some
> symlinks beforehand (for example some multiarches dirs like lib -> lib64
> in / and /usr), it works fine with dpkg, but not with debootstrap early
> extract.
>
> Would it be possible to replace the tar call in extract_dpkg_deb_data
> with tar -hxf so it will follow symlinks instead of replacing them?

Recent versions of debootstrap use `tar -k` which does keep symlinks (so
that for example symlinks from /* to /usr/* are kept for merged-/usr).
Note that this will only work for newer releases as `-k` fails in case
of file conflicts[1].

Ansgar

  [1] <https://bugs.debian.org/838388>

--- End Message ---

Reply to: