3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/applications/virtualization/virt-viewer/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

106 lines
1.9 KiB
Nix
Raw Normal View History

{ lib
, stdenv
2022-02-15 00:08:11 +00:00
, bash-completion
, fetchurl
2022-03-30 12:47:00 +01:00
, fetchpatch
, gdbm ? null
, glib
, gsettings-desktop-schemas
, gtk-vnc
, gtk3
, intltool
, libcap ? null
2022-02-15 00:08:11 +00:00
, libgovirt
, libvirt
, libvirt-glib
, libxml2
2022-02-15 00:08:11 +00:00
, meson
, ninja
, pkg-config
2022-02-15 00:08:11 +00:00
, python3
, shared-mime-info
, spice-gtk ? null
, spice-protocol ? null
, spiceSupport ? true
, vte
, wrapGAppsHook
}:
assert spiceSupport -> (
gdbm != null
&& libcap != null
&& spice-gtk != null
&& spice-protocol != null
);
2021-01-15 05:42:41 +00:00
with lib;
2015-12-24 12:08:10 +00:00
stdenv.mkDerivation rec {
2022-03-07 11:37:20 +00:00
pname = "virt-viewer";
2022-02-15 00:08:11 +00:00
version = "11.0";
src = fetchurl {
2022-03-07 11:37:20 +00:00
url = "https://releases.pagure.org/virt-viewer/virt-viewer-${version}.tar.xz";
2022-02-15 00:08:11 +00:00
sha256 = "sha256-pD+iMlxMHHelyMmAZaww7wURohrJjlkPIjQIabrZq9A=";
};
2022-03-30 12:47:00 +01:00
patches = [
# Fix build with meson 0.61
# https://gitlab.com/virt-viewer/virt-viewer/-/merge_requests/117
(fetchpatch {
url = "https://gitlab.com/virt-viewer/virt-viewer/-/commit/ed19e51407bee53988878a6ebed4e7279d00b1a1.patch";
sha256 = "sha256-3AbnkbhWOh0aNjUkmVoSV/9jFQtvTllOr7plnkntb2o=";
})
];
nativeBuildInputs = [
glib
intltool
2022-02-15 00:08:11 +00:00
meson
ninja
pkg-config
2022-02-15 00:08:11 +00:00
python3
shared-mime-info
wrapGAppsHook
];
2015-12-24 12:08:10 +00:00
buildInputs = [
2022-02-15 00:08:11 +00:00
bash-completion
glib
gsettings-desktop-schemas
gtk-vnc
gtk3
2022-02-15 00:08:11 +00:00
libgovirt
libvirt
libvirt-glib
libxml2
vte
] ++ optionals spiceSupport [
gdbm
libcap
spice-gtk
spice-protocol
];
2019-01-26 15:58:16 +00:00
# Required for USB redirection PolicyKit rules file
propagatedUserEnvPkgs = optional spiceSupport spice-gtk;
2019-08-20 19:48:38 +01:00
strictDeps = true;
2022-02-15 00:08:11 +00:00
postPatch = ''
patchShebangs build-aux/post_install.py
'';
2019-08-20 19:48:38 +01:00
meta = {
description = "A viewer for remote virtual machines";
maintainers = [ maintainers.raskin ];
platforms = platforms.linux;
license = licenses.gpl2;
};
passthru = {
updateInfo = {
downloadPage = "http://virt-manager.org/download.html";
};
};
}