Go to file
Stefan Hajnoczi ebf92608f5 Patch Cargo.toml files to enable nix "ioctl" feature
The nix "ioctl" feature is used by both the blkio and virtio-driver
crates. Neither of them enables it explicitly and this can lead to a
compilation failure:

  error[E0432]: unresolved imports `nix::ioctl_none`, `nix::ioctl_read`, `nix::ioctl_write_ptr`
    --> virtio-driver/src/transports/vhost_vdpa/vhost_vdpa_kernel.rs:17:15
     |
  17 |     use nix::{ioctl_none, ioctl_read, ioctl_write_ptr, unistd::write};
     |               ^^^^^^^^^^  ^^^^^^^^^^  ^^^^^^^^^^^^^^^ no `ioctl_write_ptr` in the root
     |               |           |
     |               |           no `ioctl_read` in the root
     |               no `ioctl_none` in the root
  error: cannot determine resolution for the macro `ioctl_read`

Fabio Valentini <decathorpe@gmail.com> identified the root cause:

  The "virtio-driver" crate depends on nix v0.24 with "default-features
  = false", however, the code obviously imports items from "nix" that
  are only present if the "ioctl" feature is enabled. This used to work
  "by accident" because some other crate in libblkio's dependency tree
  used to pull in nix v0.24 with default features enabled. This no
  longer seems to be the case (hard to tell what changed, since koschei
  was not enabled).

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
2023-04-18 17:23:40 -04:00
.gitignore Initial import 2023-01-11 12:34:16 +00:00
fix-nix-ioctl-feature.patch Patch Cargo.toml files to enable nix "ioctl" feature 2023-04-18 17:23:40 -04:00
libblkio.spec Patch Cargo.toml files to enable nix "ioctl" feature 2023-04-18 17:23:40 -04:00
sources Initial import 2023-01-11 12:34:16 +00:00