Merge pull request #184923 from wegank/libvirt-darwin

This commit is contained in:
Franz Pletz 2022-08-03 10:07:58 +02:00 committed by GitHub
commit 9a00eb9e96
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 4 deletions

View File

@ -45,8 +45,9 @@ stdenv.mkDerivation rec {
gobject-introspection
];
buildInputs = [
buildInputs = (lib.optionals stdenv.isLinux [
libcap_ng
]) ++ [
libvirt
libxml2
gobject-introspection
@ -66,6 +67,6 @@ stdenv.mkDerivation rec {
'';
homepage = "https://libvirt.org/";
license = licenses.lgpl2Plus;
platforms = platforms.linux;
platforms = platforms.unix;
};
}

View File

@ -135,6 +135,7 @@ stdenv.mkDerivation rec {
sed -i '0,/qemuxml2argvtest/{/qemuxml2argvtest/d;}' tests/meson.build
'' + optionalString isDarwin ''
sed -i '/qemucapabilitiestest/d' tests/meson.build
sed -i '/vircryptotest/d' tests/meson.build
'';
@ -222,7 +223,7 @@ stdenv.mkDerivation rec {
--replace "ggrep" "grep"
substituteInPlace src/util/virpolkit.h \
--replace '"/usr/bin/pkttyagent"' '"${polkit.bin}/bin/pkttyagent"'
--replace '"/usr/bin/pkttyagent"' '"${if isLinux then polkit.bin else "/usr"}/bin/pkttyagent"'
patchShebangs .
''
@ -268,7 +269,7 @@ stdenv.mkDerivation rec {
(feat "numactl" isLinux)
(feat "numad" isLinux)
(feat "pciaccess" isLinux)
(feat "polkit" true)
(feat "polkit" isLinux)
(feat "readline" true)
(feat "secdriver_apparmor" isLinux)
(feat "tests" true)