Package: xfslibs-dev
Severity: normal
Tags: stretch, sid
Usertags: usr, usrmerge, multiarch

Hi,

While trying to build a cross-build environment for QEMU I ran into a
problem installing xfslibs-dev. The docker build looked like this:

  #
  # Docker ppc64el cross-compiler target
  #
  # This docker target builds on the base debian image.
  #
  # Broken in Jessie
  FROM debian:stretch-slim

  # Duplicate deb line as deb-src
  RUN cat /etc/apt/sources.list | sed "s/deb/deb-src/" >> /etc/apt/sources.list

  # Add the foreign architecture we want and install dependencies
  RUN dpkg --add-architecture ppc64el
  RUN apt update && apt dist-upgrade -yy
  RUN apt-get build-dep -yy -a ppc64el qemu
  RUN apt install -yy gcc-multilib-ppc64el binutils-multiarch

  # Specify the cross prefix for this image (see tests/docker/common.rc)
  ENV QEMU_CONFIGURE_OPTS --cross-prefix=ppc64el-linux-gnu-

The error message reported by the build-dep stage was:

  Unpacking xfslibs-dev:ppc64el (4.9.0) ...
  dpkg: error processing archive 
/tmp/apt-dpkg-install-u0zpz1/10-xfslibs-dev_4.9.0_ppc64el.deb (--unpack):
   unable to install new version of '/lib/libhandle.a': No such file or 
directory
  Errors were encountered while processing:
   /tmp/apt-dpkg-install-u0zpz1/10-xfslibs-dev_4.9.0_ppc64el.deb
  E: Sub-process /usr/bin/dpkg returned an error code (1)

Testing with debian:unstable-slim produced the same result.

After discussion on #debian-bootstrap we reproduced with a simpler setup:

  <helmut> I can reproduce your problem in unstable now. fresh sid
      debootstrap amd64; dpkg --add-architecture ppc64el; apt-get
      update; apt-get install usrmerge; apt-get install
      xfslibs-dev:ppc64el # reproduces

There seems to be debate as to if this is a straight up multi-arch bug
or a user merge bug so I've tagged them as both for now. Certainly
static libraries need to be properly placed in the relevant multi-arch
paths but this seems to work for arm64 and armhf (which I have also set
up QEMU cross build environments for).

---
Alex Bennée

Reply via email to