From 037387d4ba374f2c03cf26590ff143ba459e7cfc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gutyina=20Gerg=C5=91?= Date: Wed, 2 Jul 2025 10:30:49 +0200 Subject: [PATCH] libxml2: get rid of generic arguments --- pkgs/development/libraries/libxml2/default.nix | 11 +++++++++-- pkgs/top-level/all-packages.nix | 8 +------- pkgs/top-level/python-packages.nix | 2 +- 3 files changed, 11 insertions(+), 10 deletions(-) diff --git a/pkgs/development/libraries/libxml2/default.nix b/pkgs/development/libraries/libxml2/default.nix index 1a411f3b2130..6b366fbd4e11 100644 --- a/pkgs/development/libraries/libxml2/default.nix +++ b/pkgs/development/libraries/libxml2/default.nix @@ -1,11 +1,12 @@ { stdenv, + darwin, lib, fetchFromGitLab, pkg-config, autoreconfHook, libintl, - python, + python3, gettext, ncurses, findXMLCatalogs, @@ -31,7 +32,13 @@ enableHttp ? false, }: -stdenv.mkDerivation (finalAttrs: { +let + python = python3; + # libxml2 is a dependency of xcbuild. Avoid an infinite recursion by using a bootstrap stdenv + # that does not propagate xcrun. + stdenv' = if stdenv.hostPlatform.isDarwin then darwin.bootstrapStdenv else stdenv; +in +stdenv'.mkDerivation (finalAttrs: { pname = "libxml2"; version = "2.14.5"; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index b33f85874c21..d997a1b6824e 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -8835,13 +8835,7 @@ with pkgs; libxcrypt-legacy = libxcrypt.override { enableHashes = "all"; }; libxkbcommon = libxkbcommon_8; - libxml2 = callPackage ../development/libraries/libxml2 { - python = python3; - stdenv = - # libxml2 is a dependency of xcbuild. Avoid an infinite recursion by using a bootstrap stdenv - # that does not propagate xcrun. - if stdenv.hostPlatform.isDarwin then darwin.bootstrapStdenv else stdenv; - }; + libxml2 = callPackage ../development/libraries/libxml2 { }; libxml2Python = let diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index d231cd21957d..9a82087429b6 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -8234,7 +8234,7 @@ self: super: with self; { (toPythonModule ( pkgs.libxml2.override { pythonSupport = true; - inherit python; + python3 = python; } )).py;