From d5b0c8bcdf594111b096480287364e0140157355 Mon Sep 17 00:00:00 2001 From: Bas van Dijk Date: Sat, 26 Sep 2020 18:19:31 +0200 Subject: [PATCH 1/9] libvirt: 6.3.0 -> 6.6.0 Also upgrades `python3Packages.libvirt` and patches the `rpcgen` tool from Apple's `developer_cmds` package. --- .../0001-Fix-build-with-libtirpc.patch | 106 ------------------ .../development/libraries/libvirt/default.nix | 24 ++-- .../python-modules/libvirt/default.nix | 4 +- .../developer_cmds/default.nix | 13 ++- .../rpcgen-support-hyper-and-quad-types.patch | 66 +++++++++++ 5 files changed, 92 insertions(+), 121 deletions(-) delete mode 100644 pkgs/development/libraries/libvirt/0001-Fix-build-with-libtirpc.patch create mode 100644 pkgs/os-specific/darwin/apple-source-releases/developer_cmds/rpcgen-support-hyper-and-quad-types.patch diff --git a/pkgs/development/libraries/libvirt/0001-Fix-build-with-libtirpc.patch b/pkgs/development/libraries/libvirt/0001-Fix-build-with-libtirpc.patch deleted file mode 100644 index 2039126e889..00000000000 --- a/pkgs/development/libraries/libvirt/0001-Fix-build-with-libtirpc.patch +++ /dev/null @@ -1,106 +0,0 @@ -From a9ce1217742d542a5ae4b154b6f55342aace374e Mon Sep 17 00:00:00 2001 -From: Maximilian Bosch -Date: Mon, 17 Aug 2020 19:35:44 +0200 -Subject: [PATCH] Fix build with libtirpc - -Derived from https://github.com/libvirt/libvirt/commit/d7147b3797380de2d159ce6324536f3e1f2d97e3.patch ---- - libvirt.spec.in | 4 +++- - src/Makefile.am | 2 +- - src/admin/Makefile.inc.am | 1 + - src/locking/Makefile.inc.am | 2 ++ - src/logging/Makefile.inc.am | 1 + - src/remote/Makefile.inc.am | 1 + - 6 files changed, 9 insertions(+), 2 deletions(-) - -diff --git a/libvirt.spec.in b/libvirt.spec.in -index 6abf97d..71fc4e6 100644 ---- a/libvirt.spec.in -+++ b/libvirt.spec.in -@@ -405,11 +405,13 @@ BuildRequires: wireshark-devel >= 2.4.0 - BuildRequires: libssh-devel >= 0.7.0 - %endif - -+# On RHEL-7 rpcgen is still part of glibc-common package - %if 0%{?fedora} || 0%{?rhel} > 7 - BuildRequires: rpcgen --BuildRequires: libtirpc-devel - %endif - -+BuildRequires: libtirpc-devel -+ - %if %{with_firewalld_zone} - BuildRequires: firewalld-filesystem - %endif -diff --git a/src/Makefile.am b/src/Makefile.am -index 12dd6b8..8d0d4e1 100644 ---- a/src/Makefile.am -+++ b/src/Makefile.am -@@ -439,7 +439,7 @@ libvirt_la_LDFLAGS += -Wl,-flat_namespace - endif WITH_MACOS - libvirt_la_LDFLAGS += $(NULL) - libvirt_la_LIBADD += \ -- $(DRIVER_MODULES_LIBS) -+ $(DRIVER_MODULES_LIBS) $(XDR_LIBS) - libvirt_la_CFLAGS = -DIN_LIBVIRT $(AM_CFLAGS) - # Because we specify libvirt_la_DEPENDENCIES for $(LIBVIRT_SYMBOL_FILE), we - # lose automake's automatic dependencies on an appropriate subset of -diff --git a/src/admin/Makefile.inc.am b/src/admin/Makefile.inc.am -index 0a9717a..8556a3b 100644 ---- a/src/admin/Makefile.inc.am -+++ b/src/admin/Makefile.inc.am -@@ -72,6 +72,7 @@ libvirt_admin_la_LDFLAGS = \ - - libvirt_admin_la_LIBADD = \ - libvirt.la \ -+ $(XDR_LIBS) \ - $(CAPNG_LIBS) \ - $(YAJL_LIBS) \ - $(DEVMAPPER_LIBS) \ -diff --git a/src/locking/Makefile.inc.am b/src/locking/Makefile.inc.am -index d1bf49c..ab01d8e 100644 ---- a/src/locking/Makefile.inc.am -+++ b/src/locking/Makefile.inc.am -@@ -120,6 +120,7 @@ lockd_la_LDFLAGS = $(AM_LDFLAGS_MOD_NOUNDEF) - lockd_la_LIBADD = \ - libvirt.la \ - $(GLIB_LIBS) \ -+ $(XDR_LIBS) \ - $(NULL) - augeas_DATA += locking/libvirt_lockd.aug - if WITH_DTRACE_PROBES -@@ -161,6 +162,7 @@ virtlockd_CFLAGS = \ - virtlockd_LDFLAGS = \ - $(AM_LDFLAGS) \ - $(PIE_LDFLAGS) \ -+ $(XDR_LIBS) \ - $(NO_UNDEFINED_LDFLAGS) \ - $(NULL) - virtlockd_LDADD = \ -diff --git a/src/logging/Makefile.inc.am b/src/logging/Makefile.inc.am -index dc09cfe..4be3376 100644 ---- a/src/logging/Makefile.inc.am -+++ b/src/logging/Makefile.inc.am -@@ -99,6 +99,7 @@ virtlogd_CFLAGS = \ - virtlogd_LDFLAGS = \ - $(AM_LDFLAGS) \ - $(PIE_LDFLAGS) \ -+ $(XDR_LIBS) \ - $(NO_UNDEFINED_LDFLAGS) \ - $(NULL) - virtlogd_LDADD = \ -diff --git a/src/remote/Makefile.inc.am b/src/remote/Makefile.inc.am -index 1b1be83..8a40c96 100644 ---- a/src/remote/Makefile.inc.am -+++ b/src/remote/Makefile.inc.am -@@ -69,6 +69,7 @@ REMOTE_DAEMON_LD_ADD = \ - $(LIBXML_LIBS) \ - $(GNUTLS_LIBS) \ - $(SASL_LIBS) \ -+ $(XDR_LIBS) \ - $(DBUS_LIBS) \ - $(LIBNL_LIBS) \ - $(NULL) --- -2.25.4 - diff --git a/pkgs/development/libraries/libvirt/default.nix b/pkgs/development/libraries/libvirt/default.nix index d8501a5b080..814b82b07dd 100644 --- a/pkgs/development/libraries/libvirt/default.nix +++ b/pkgs/development/libraries/libvirt/default.nix @@ -4,7 +4,7 @@ , iproute, iptables, readline, lvm2, utillinux, systemd, libpciaccess, gettext , libtasn1, ebtables, libgcrypt, yajl, pmutils, libcap_ng, libapparmor , dnsmasq, libnl, libpcap, libxslt, xhtml1, numad, numactl, perlPackages -, curl, libiconv, gmp, zfs, parted, bridge-utils, dmidecode, dbus, libtirpc, rpcsvc-proto +, curl, libiconv, gmp, zfs, parted, bridge-utils, dmidecode, dbus, libtirpc, rpcsvc-proto, darwin , enableXen ? false, xen ? null , enableIscsi ? false, openiscsi , enableCeph ? false, ceph @@ -17,34 +17,38 @@ let buildFromTarball = stdenv.isDarwin; in stdenv.mkDerivation rec { pname = "libvirt"; - version = "6.3.0"; + version = "6.6.0"; src = if buildFromTarball then fetchurl { url = "http://libvirt.org/sources/${pname}-${version}.tar.xz"; - sha256 = "1xcng497hs1gary3pz3fp590a4r1kqs4d0d8k5p370j0scw981kl"; + sha256 = "1y8y13zvh820f4b15287wb77wq7ra7kbfnpblzhm1dki5pfjvrcl"; } else fetchgit { url = "git://libvirt.org/libvirt.git"; rev = "v${version}"; - sha256 = "129b3p72jlb40dsidak3nvpssv75xx2v99y63gzp5k074fp8y8x4"; + sha256 = "09hsbm2qmx0jfmm418rf5lx374g85bwgg0kzlga62x5180jhsssn"; fetchSubmodules = true; }; - patches = [ - ./0001-Fix-build-with-libtirpc.patch + nativeBuildInputs = [ + makeWrapper pkgconfig docutils + ] ++ optionals (!buildFromTarball) [ + autoreconfHook + ] ++ optional (!stdenv.isDarwin) [ + rpcsvc-proto + ] ++ optionals stdenv.isDarwin [ + darwin.developer_cmds # needed for rpcgen ]; - nativeBuildInputs = [ makeWrapper pkgconfig docutils rpcsvc-proto ] - ++ optionals (!buildFromTarball) [ autoreconfHook ]; buildInputs = [ libxml2 gnutls perl python2 readline gettext libtasn1 libgcrypt yajl - libxslt xhtml1 perlPackages.XMLXPath curl libpcap glib dbus libtirpc + libxslt xhtml1 perlPackages.XMLXPath curl libpcap glib dbus ] ++ optionals stdenv.isLinux [ libpciaccess lvm2 utillinux systemd libnl numad zfs - libapparmor libcap_ng numactl attr parted + libapparmor libcap_ng numactl attr parted libtirpc ] ++ optionals (enableXen && stdenv.isLinux && stdenv.isx86_64) [ xen ] ++ optionals enableIscsi [ diff --git a/pkgs/development/python-modules/libvirt/default.nix b/pkgs/development/python-modules/libvirt/default.nix index 7b1601a4122..fd9127c8a69 100644 --- a/pkgs/development/python-modules/libvirt/default.nix +++ b/pkgs/development/python-modules/libvirt/default.nix @@ -2,12 +2,12 @@ buildPythonPackage rec { pname = "libvirt"; - version = "6.3.0"; + version = "6.6.0"; src = assert version == libvirt.version; fetchgit { url = "git://libvirt.org/libvirt-python.git"; rev = "v${version}"; - sha256 = "088cksq59jxkkzbvmwl8jw9v2k3zibwksl7j57yb51bxaa2sa1cx"; + sha256 = "0jj6b2nlx7qldwbvixz74abn3p0sq4lkf6ak74vynrv5xvlycb9v"; }; nativeBuildInputs = [ pkgconfig ]; diff --git a/pkgs/os-specific/darwin/apple-source-releases/developer_cmds/default.nix b/pkgs/os-specific/darwin/apple-source-releases/developer_cmds/default.nix index 21971ea2e28..cfd13b1b049 100644 --- a/pkgs/os-specific/darwin/apple-source-releases/developer_cmds/default.nix +++ b/pkgs/os-specific/darwin/apple-source-releases/developer_cmds/default.nix @@ -1,11 +1,18 @@ -{ stdenv, appleDerivation, xcbuildHook }: +{ stdenv, appleDerivation, xcbuildHook, llvmPackages }: appleDerivation { nativeBuildInputs = [ xcbuildHook ]; - patchPhase = '' + patches = [ + # The following copied from + # https://github.com/Homebrew/homebrew-core/commit/712ed3e948868e17f96b7e59972b5f45d4faf688 + # is needed to build libvirt. + ./rpcgen-support-hyper-and-quad-types.patch + ]; + + postPatch = '' substituteInPlace rpcgen/rpc_main.c \ - --replace "/usr/bin/cpp" "${stdenv.cc}/bin/cpp" + --replace "/usr/bin/cpp" "${llvmPackages.clang-unwrapped}/bin/clang-cpp" ''; # temporary install phase until xcodebuild has "install" support diff --git a/pkgs/os-specific/darwin/apple-source-releases/developer_cmds/rpcgen-support-hyper-and-quad-types.patch b/pkgs/os-specific/darwin/apple-source-releases/developer_cmds/rpcgen-support-hyper-and-quad-types.patch new file mode 100644 index 00000000000..481cf0f3e05 --- /dev/null +++ b/pkgs/os-specific/darwin/apple-source-releases/developer_cmds/rpcgen-support-hyper-and-quad-types.patch @@ -0,0 +1,66 @@ +diff --git a/rpcgen/rpc_parse.c b/rpcgen/rpc_parse.c +index 52edc9f..db0c1f1 100644 +--- a/rpcgen/rpc_parse.c ++++ b/rpcgen/rpc_parse.c +@@ -580,6 +580,10 @@ get_type(prefixp, typep, dkind) + *typep = "long"; + (void) peekscan(TOK_INT, &tok); + break; ++ case TOK_HYPER: ++ *typep = "int64_t"; ++ (void) peekscan(TOK_INT, &tok); ++ break; + case TOK_VOID: + if (dkind != DEF_UNION && dkind != DEF_PROGRAM) { + error("voids allowed only inside union and program definitions with one argument"); +@@ -592,6 +596,7 @@ get_type(prefixp, typep, dkind) + case TOK_INT: + case TOK_FLOAT: + case TOK_DOUBLE: ++ case TOK_QUAD: + case TOK_BOOL: + *typep = tok.str; + break; +@@ -622,6 +627,11 @@ unsigned_dec(typep) + *typep = "u_long"; + (void) peekscan(TOK_INT, &tok); + break; ++ case TOK_HYPER: ++ get_token(&tok); ++ *typep = "u_int64_t"; ++ (void) peekscan(TOK_INT, &tok); ++ break; + case TOK_INT: + get_token(&tok); + *typep = "u_int"; +diff --git a/rpcgen/rpc_scan.c b/rpcgen/rpc_scan.c +index a8df441..4130107 100644 +--- a/rpcgen/rpc_scan.c ++++ b/rpcgen/rpc_scan.c +@@ -419,8 +419,10 @@ static token symbols[] = { + {TOK_UNSIGNED, "unsigned"}, + {TOK_SHORT, "short"}, + {TOK_LONG, "long"}, ++ {TOK_HYPER, "hyper"}, + {TOK_FLOAT, "float"}, + {TOK_DOUBLE, "double"}, ++ {TOK_QUAD, "quadruple"}, + {TOK_STRING, "string"}, + {TOK_PROGRAM, "program"}, + {TOK_VERSION, "version"}, +diff --git a/rpcgen/rpc_scan.h b/rpcgen/rpc_scan.h +index bac2be4..e4c57c8 100644 +--- a/rpcgen/rpc_scan.h ++++ b/rpcgen/rpc_scan.h +@@ -66,9 +66,11 @@ enum tok_kind { + TOK_INT, + TOK_SHORT, + TOK_LONG, ++ TOK_HYPER, + TOK_UNSIGNED, + TOK_FLOAT, + TOK_DOUBLE, ++ TOK_QUAD, + TOK_OPAQUE, + TOK_CHAR, + TOK_STRING, \ No newline at end of file From 4606528fcbad11587c5e30abf8fd50d884526631 Mon Sep 17 00:00:00 2001 From: Bas van Dijk Date: Tue, 29 Sep 2020 09:45:13 +0200 Subject: [PATCH 2/9] libvirt: update homepage to https URL --- pkgs/development/libraries/libvirt/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/libraries/libvirt/default.nix b/pkgs/development/libraries/libvirt/default.nix index 814b82b07dd..4af71876179 100644 --- a/pkgs/development/libraries/libvirt/default.nix +++ b/pkgs/development/libraries/libvirt/default.nix @@ -137,7 +137,7 @@ in stdenv.mkDerivation rec { NIX_CFLAGS_COMPILE = "-fno-stack-protector"; meta = { - homepage = "http://libvirt.org/"; + homepage = "https://libvirt.org/"; repositories.git = "git://libvirt.org/libvirt.git"; description = '' A toolkit to interact with the virtualization capabilities of recent From de15287183a2b6b930b7354c7e589f57310debee Mon Sep 17 00:00:00 2001 From: Bas van Dijk Date: Tue, 29 Sep 2020 09:58:48 +0200 Subject: [PATCH 3/9] libvirt: update autoconf 1.70 comment to 2.70 --- pkgs/development/libraries/libvirt/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/libraries/libvirt/default.nix b/pkgs/development/libraries/libvirt/default.nix index 4af71876179..c045585bc36 100644 --- a/pkgs/development/libraries/libvirt/default.nix +++ b/pkgs/development/libraries/libvirt/default.nix @@ -74,7 +74,7 @@ in stdenv.mkDerivation rec { dontAddDisableDepTrack = true; configureFlags = [ - "--with-runstatedir=/run" # TODO: remove when autoconf 1.70 is released + "--with-runstatedir=/run" # TODO: remove when autoconf 2.70 is released "--localstatedir=/var" "--sysconfdir=/var/lib" "--with-libpcap" From 8d995c440de231b1f78f7ad96a296639584ad8ff Mon Sep 17 00:00:00 2001 From: Bas van Dijk Date: Tue, 29 Sep 2020 10:03:36 +0200 Subject: [PATCH 4/9] libvirt: remove -fno-stack-protector because it builds without it --- pkgs/development/libraries/libvirt/default.nix | 2 -- 1 file changed, 2 deletions(-) diff --git a/pkgs/development/libraries/libvirt/default.nix b/pkgs/development/libraries/libvirt/default.nix index c045585bc36..b8edf1168a2 100644 --- a/pkgs/development/libraries/libvirt/default.nix +++ b/pkgs/development/libraries/libvirt/default.nix @@ -134,8 +134,6 @@ in stdenv.mkDerivation rec { enableParallelBuilding = true; - NIX_CFLAGS_COMPILE = "-fno-stack-protector"; - meta = { homepage = "https://libvirt.org/"; repositories.git = "git://libvirt.org/libvirt.git"; From 3acb90e7dd30752f34aa916a3f475d42cf1070d4 Mon Sep 17 00:00:00 2001 From: Bas van Dijk Date: Tue, 29 Sep 2020 10:09:09 +0200 Subject: [PATCH 5/9] libvirt: update source URLs to https --- pkgs/development/libraries/libvirt/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/libvirt/default.nix b/pkgs/development/libraries/libvirt/default.nix index b8edf1168a2..c89679ed6fa 100644 --- a/pkgs/development/libraries/libvirt/default.nix +++ b/pkgs/development/libraries/libvirt/default.nix @@ -22,12 +22,12 @@ in stdenv.mkDerivation rec { src = if buildFromTarball then fetchurl { - url = "http://libvirt.org/sources/${pname}-${version}.tar.xz"; + url = "https://libvirt.org/sources/${pname}-${version}.tar.xz"; sha256 = "1y8y13zvh820f4b15287wb77wq7ra7kbfnpblzhm1dki5pfjvrcl"; } else fetchgit { - url = "git://libvirt.org/libvirt.git"; + url = "https://libvirt.org/git/libvirt.git"; rev = "v${version}"; sha256 = "09hsbm2qmx0jfmm418rf5lx374g85bwgg0kzlga62x5180jhsssn"; fetchSubmodules = true; From af8409fc0a7bfe21241d18185f7b3e0523e703c0 Mon Sep 17 00:00:00 2001 From: Bas van Dijk Date: Thu, 1 Oct 2020 10:55:56 +0200 Subject: [PATCH 6/9] libvirt: fetch sources from gitlab That seems to be the official repository now. --- pkgs/development/libraries/libvirt/default.nix | 2 +- pkgs/development/python-modules/libvirt/default.nix | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pkgs/development/libraries/libvirt/default.nix b/pkgs/development/libraries/libvirt/default.nix index c89679ed6fa..642baba4376 100644 --- a/pkgs/development/libraries/libvirt/default.nix +++ b/pkgs/development/libraries/libvirt/default.nix @@ -27,7 +27,7 @@ in stdenv.mkDerivation rec { } else fetchgit { - url = "https://libvirt.org/git/libvirt.git"; + url = "https://gitlab.com/libvirt/libvirt.git"; rev = "v${version}"; sha256 = "09hsbm2qmx0jfmm418rf5lx374g85bwgg0kzlga62x5180jhsssn"; fetchSubmodules = true; diff --git a/pkgs/development/python-modules/libvirt/default.nix b/pkgs/development/python-modules/libvirt/default.nix index fd9127c8a69..e84dd1fbc24 100644 --- a/pkgs/development/python-modules/libvirt/default.nix +++ b/pkgs/development/python-modules/libvirt/default.nix @@ -5,7 +5,7 @@ buildPythonPackage rec { version = "6.6.0"; src = assert version == libvirt.version; fetchgit { - url = "git://libvirt.org/libvirt-python.git"; + url = "https://gitlab.com/libvirt/libvirt-python.git"; rev = "v${version}"; sha256 = "0jj6b2nlx7qldwbvixz74abn3p0sq4lkf6ak74vynrv5xvlycb9v"; }; @@ -19,7 +19,7 @@ buildPythonPackage rec { ''; meta = with stdenv.lib; { - homepage = "http://www.libvirt.org/"; + homepage = "https://libvirt.org/python.html"; description = "libvirt Python bindings"; license = licenses.lgpl2; maintainers = [ maintainers.fpletz ]; From 934cd8c322459cbb373d6b82eeff91c37870bafe Mon Sep 17 00:00:00 2001 From: Bas van Dijk Date: Thu, 1 Oct 2020 11:53:47 +0200 Subject: [PATCH 7/9] perlPackages.SysVirt: remove assert version == pkgs.libvirt.version SysVirt-6.3.0 should build correctly against libvirt-6.6.0 and also libvirt-6.7.0 since their were no API changes. Also note that because of this there's no SysVirt-6.6.0 release. So this removes the `assert version == pkgs.libvirt.version` protection. --- pkgs/top-level/perl-packages.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/top-level/perl-packages.nix b/pkgs/top-level/perl-packages.nix index d7abe0ecd30..e1f6a4ef2de 100644 --- a/pkgs/top-level/perl-packages.nix +++ b/pkgs/top-level/perl-packages.nix @@ -18419,8 +18419,8 @@ let SysVirt = buildPerlModule rec { pname = "Sys-Virt"; version = "6.3.0"; - src = assert version == pkgs.libvirt.version; fetchgit { - url = "git://libvirt.org/libvirt-perl.git"; + src = fetchgit { + url = "https://gitlab.com/libvirt/libvirt-perl.git"; rev = "v${version}"; sha256 = "0m75g0kf2dmllx5c1wxzszm1zakiqjighcsjbgq66674pvqf5mk7"; }; From 54de740a87a301fb4f98bd45728a1132bbb1574b Mon Sep 17 00:00:00 2001 From: Bas van Dijk Date: Thu, 1 Oct 2020 12:28:29 +0200 Subject: [PATCH 8/9] perlPackages.SysVirt: fetch source from CPAN Co-authored-by: Stig P --- pkgs/top-level/perl-packages.nix | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/pkgs/top-level/perl-packages.nix b/pkgs/top-level/perl-packages.nix index e1f6a4ef2de..42789c9c710 100644 --- a/pkgs/top-level/perl-packages.nix +++ b/pkgs/top-level/perl-packages.nix @@ -18419,10 +18419,9 @@ let SysVirt = buildPerlModule rec { pname = "Sys-Virt"; version = "6.3.0"; - src = fetchgit { - url = "https://gitlab.com/libvirt/libvirt-perl.git"; - rev = "v${version}"; - sha256 = "0m75g0kf2dmllx5c1wxzszm1zakiqjighcsjbgq66674pvqf5mk7"; + src = fetchurl { + url = "mirror://cpan/authors/id/D/DA/DANBERR/Sys-Virt-v6.3.0.tar.gz"; + sha256 = "6333fe3c554322fec5a3e1890b08a4ea4f39b0fbb506b3592688a5785a488f39"; }; nativeBuildInputs = [ pkgs.pkgconfig ]; buildInputs = [ pkgs.libvirt CPANChanges TestPod TestPodCoverage XMLXPath ]; From e366ad9684cad681069df4e243b346e4b2cd4352 Mon Sep 17 00:00:00 2001 From: Bas van Dijk Date: Thu, 1 Oct 2020 12:45:47 +0200 Subject: [PATCH 9/9] python3Packages.libvirt: fetch source using fetchFromGitLab --- pkgs/development/python-modules/libvirt/default.nix | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/pkgs/development/python-modules/libvirt/default.nix b/pkgs/development/python-modules/libvirt/default.nix index e84dd1fbc24..4c0e730f7d5 100644 --- a/pkgs/development/python-modules/libvirt/default.nix +++ b/pkgs/development/python-modules/libvirt/default.nix @@ -1,11 +1,12 @@ -{ stdenv, buildPythonPackage, fetchgit, pkgconfig, lxml, libvirt, nose }: +{ stdenv, buildPythonPackage, fetchFromGitLab, pkgconfig, lxml, libvirt, nose }: buildPythonPackage rec { pname = "libvirt"; version = "6.6.0"; - src = assert version == libvirt.version; fetchgit { - url = "https://gitlab.com/libvirt/libvirt-python.git"; + src = assert version == libvirt.version; fetchFromGitLab { + owner = "libvirt"; + repo = "libvirt-python"; rev = "v${version}"; sha256 = "0jj6b2nlx7qldwbvixz74abn3p0sq4lkf6ak74vynrv5xvlycb9v"; };