libxslt: make python3 an input

This commit is contained in:
Ivan Babrou 2021-01-29 18:01:55 -08:00 committed by Frederik Rietdijk
parent 86de9261f8
commit b2ce768e60
3 changed files with 6 additions and 8 deletions

View File

@ -1,4 +1,4 @@
{ lib, stdenv, fetchurl, fetchpatch, libxml2, findXMLCatalogs, gettext, python, libgcrypt { lib, stdenv, fetchurl, fetchpatch, libxml2, findXMLCatalogs, gettext, python3, libgcrypt
, cryptoSupport ? false , cryptoSupport ? false
, pythonSupport ? stdenv.buildPlatform == stdenv.hostPlatform , pythonSupport ? stdenv.buildPlatform == stdenv.hostPlatform
}: }:
@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
buildInputs = [ libxml2.dev ] buildInputs = [ libxml2.dev ]
++ lib.optional stdenv.isDarwin gettext ++ lib.optional stdenv.isDarwin gettext
++ lib.optionals pythonSupport [ libxml2.py python ] ++ lib.optionals pythonSupport [ libxml2.py python3 ]
++ lib.optionals cryptoSupport [ libgcrypt ]; ++ lib.optionals cryptoSupport [ libgcrypt ];
propagatedBuildInputs = [ findXMLCatalogs ]; propagatedBuildInputs = [ findXMLCatalogs ];
@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
"--without-debug" "--without-debug"
"--without-mem-debug" "--without-mem-debug"
"--without-debugger" "--without-debugger"
] ++ lib.optional pythonSupport "--with-python=${python}" ] ++ lib.optional pythonSupport "--with-python=${python3}"
++ lib.optional (!cryptoSupport) "--without-crypto"; ++ lib.optional (!cryptoSupport) "--without-crypto";
postFixup = '' postFixup = ''
@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
'' + lib.optionalString pythonSupport '' '' + lib.optionalString pythonSupport ''
mkdir -p $py/nix-support mkdir -p $py/nix-support
echo ${libxml2.py} >> $py/nix-support/propagated-build-inputs echo ${libxml2.py} >> $py/nix-support/propagated-build-inputs
moveToOutput ${python.libPrefix} "$py" moveToOutput ${python3.libPrefix} "$py"
''; '';
passthru = { passthru = {

View File

@ -15565,9 +15565,7 @@ in
libxmp = callPackage ../development/libraries/libxmp { }; libxmp = callPackage ../development/libraries/libxmp { };
libxslt = callPackage ../development/libraries/libxslt { libxslt = callPackage ../development/libraries/libxslt { };
python = python3;
};
libxsmm = callPackage ../development/libraries/libxsmm { }; libxsmm = callPackage ../development/libraries/libxsmm { };

View File

@ -3716,7 +3716,7 @@ in {
libxslt = (toPythonModule (pkgs.libxslt.override { libxslt = (toPythonModule (pkgs.libxslt.override {
pythonSupport = true; pythonSupport = true;
inherit python; python3 = python;
inherit (self) libxml2; inherit (self) libxml2;
})).py; })).py;