Skip to content

Commit

Permalink
app-emulation/virtiofsd: Install 50-qemu-virtiofsd.json
Browse files Browse the repository at this point in the history
With the old virtiofsd provided by app-emulation/qemu the
corresponding JSON file descriptor is installed by QEMU. But with
this new rust version, we have to install it ourselves in order
for libvirt to pick it up. To avoid conflicts with the file
installed by app-emulation/qemu we can install it under a
different name. And because smaller number means higher priority
let's go with "40-qemu-virtiofsd.json" so that users with
<app-emulation/qemu-8.0.0 can benefit from rust version of the
daemon (if both are installed).

Closes: https://bugs.gentoo.org/909372
Signed-off-by: Michal Privoznik <[email protected]>
Signed-off-by: Sam James <[email protected]>
  • Loading branch information
zippy2 authored and thesamesam committed Jul 2, 2023
1 parent f8321a7 commit cd59e8c
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -124,3 +124,15 @@ src_unpack() {
cargo_src_unpack
fi
}

src_install() {
cargo_src_install

# Install 50-qemu-virtiofsd.json but to avoid conflicts with
# <app-emulation/qemu-8.0.0 install it under different name. In this case,
# smaller number means higher priority, but that's probably what users want
# anyway if they install this package on top of app-emulation/qemu.
# TODO: remove once old QEMUs are removed from the portage.
insinto "/usr/share/qemu/vhost-user"
newins "50-qemu-virtiofsd.json" "40-qemu-virtiofsd.json"
}
12 changes: 12 additions & 0 deletions app-emulation/virtiofsd/virtiofsd-9999.ebuild
Original file line number Diff line number Diff line change
Expand Up @@ -124,3 +124,15 @@ src_unpack() {
cargo_src_unpack
fi
}

src_install() {
cargo_src_install

# Install 50-qemu-virtiofsd.json but to avoid conflicts with
# <app-emulation/qemu-8.0.0 install it under different name. In this case,
# smaller number means higher priority, but that's probably what users want
# anyway if they install this package on top of app-emulation/qemu.
# TODO: remove once old QEMUs are removed from the portage.
insinto "/usr/share/qemu/vhost-user"
newins "50-qemu-virtiofsd.json" "40-qemu-virtiofsd.json"
}

0 comments on commit cd59e8c

Please sign in to comment.