#1149481 rust-regalloc2: FTBFS: failed to select a version for the requirement `bincode = "^1.3.3"`

#1149481#5
Date:
2026-09-29 23:06:51 UTC
From:
To:
Dear maintainer:

During a rebuild of all packages in unstable, this package failed to build.

Below you will find the last part of the build log (probably the most
relevant part, but not necessarily). If required, the full build log
is available here:

https://people.debian.org/~sanvila/build-logs/202609/

About the archive rebuild: The build was made on virtual machines from AWS,
using sbuild and a reduced chroot with only build-essential packages.

If you cannot reproduce the bug please contact me privately, as I
am willing to provide ssh access to a virtual machine where the bug is
fully reproducible.

If this is really a bug in one of the build-depends, please use
reassign and add an affects on src:rust-regalloc2, so that this is still
visible in the BTS web page for this package.

Thanks.
--------------------------------------------------------------------------------
[...]
  Installing regalloc2-tool v0.0.0 (/<<PKGBUILDDIR>>/regalloc2-tool)
error: failed to compile `regalloc2-tool v0.0.0 (/<<PKGBUILDDIR>>/regalloc2-tool)`, intermediate artifacts can be found at `/<<PKGBUILDDIR>>/target`.
To reuse those artifacts with a future compilation, set the environment variable `CARGO_BUILD_BUILD_DIR` to that path.

Caused by:
  failed to select a version for the requirement `bincode = "^1.3.3"`
  candidate versions found which didn't match: 2.0.1
  location searched: directory source `/<<PKGBUILDDIR>>/debian/cargo_registry` (which is replacing registry `crates-io`)
  required by package `regalloc2-tool v0.0.0 (/<<PKGBUILDDIR>>/regalloc2-tool)`
  perhaps a crate was updated and forgotten to be re-vendored?
Traceback (most recent call last):
  File "/usr/share/dh-rust/bin/cargo", line 265, in <module>
    sys.exit(main(*sys.argv[1:]))
             ~~~~^^^^^^^^^^^^^^^
  File "/usr/share/dh-rust/bin/cargo", line 255, in main
    return install(os.getenv("DESTDIR", ""),
        os.environ["DEB_CARGO_CRATE"],
    ...<2 lines>...
        os.getenv("DEB_CARGO_INSTALL_PREFIX", "/usr"),
        *newargs)
  File "/usr/share/dh-rust/bin/cargo", line 128, in install
    logrun(["env", "RUST_BACKTRACE=1",
    ~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        # set CARGO_TARGET_DIR so build products are saved in target/
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    ...<3 lines>...
        ([crate, "--vers", version] if crate_in_registry else path_args) +
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        ["--root", install_target], check=True)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/share/dh-rust/bin/cargo", line 81, in logrun
    return subprocess.run(*args, **kwargs)
           ~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.14/subprocess.py", line 578, in run
    raise CalledProcessError(retcode, process.args,
                             output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['env', 'RUST_BACKTRACE=1', 'CARGO_TARGET_DIR=/<<PKGBUILDDIR>>/target', '/usr/bin/cargo', '-Zavoid-dev-deps', 'install', '--profile', 'release', '--verbose', '--verbose', '-j1', '--target', 'x86_64-unknown-linux-gnu', '--path', 'regalloc2-tool', '--root', 'debian/regalloc2-tool/usr']' returned non-zero exit status 101.
dh_auto_install: error: env DEB_CARGO_CRATE=regalloc2-tool_0.0.0 DEB_BUILDDIR=target DESTDIR=debian/regalloc2-tool /usr/share/dh-rust/bin/cargo install --path regalloc2-tool returned exit code 1
make: *** [debian/rules:21: binary] Error 25
dpkg-buildpackage: error: debian/rules binary subprocess failed with exit status 2
--------------------------------------------------------------------------------