Add `hyDefinedPythonPackages` parameter to allow backwards compatibility with interpreters/hy. Fixes https://github.com/NixOS/nixpkgs/issues/171428.main
parent
e0b9154e58
commit
72fd5b71bc
@ -1,40 +0,0 @@ |
||||
{ lib |
||||
, python3Packages |
||||
, hyDefinedPythonPackages /* Packages like with python.withPackages */ |
||||
, ... |
||||
}: |
||||
python3Packages.buildPythonApplication rec { |
||||
pname = "hy"; |
||||
version = "1.0a1"; |
||||
|
||||
src = python3Packages.fetchPypi { |
||||
inherit pname version; |
||||
sha256 = "sha256-lCrbvbkeutSNmvvn/eHpTnJwPb5aEH7hWTXYSE+AJmU="; |
||||
}; |
||||
|
||||
checkInputs = with python3Packages; [ flake8 pytest ]; |
||||
|
||||
propagatedBuildInputs = with python3Packages; [ |
||||
appdirs |
||||
astor |
||||
clint |
||||
colorama |
||||
fastentrypoints |
||||
funcparserlib |
||||
rply |
||||
pygments |
||||
] ++ (hyDefinedPythonPackages python3Packages); |
||||
|
||||
# Hy does not include tests in the source distribution from PyPI, so only test executable. |
||||
checkPhase = '' |
||||
$out/bin/hy --help > /dev/null |
||||
''; |
||||
|
||||
meta = with lib; { |
||||
description = "A LISP dialect embedded in Python"; |
||||
homepage = "https://hylang.org/"; |
||||
license = licenses.mit; |
||||
maintainers = with maintainers; [ nixy mazurel ]; |
||||
platforms = platforms.all; |
||||
}; |
||||
} |
@ -1,15 +0,0 @@ |
||||
{ lib |
||||
, callPackage |
||||
, hyDefinedPythonPackages ? python-packages: [] /* Packages like with python.withPackages */ |
||||
}: |
||||
let |
||||
withPackages = ( |
||||
python-packages: callPackage ./builder.nix { |
||||
hyDefinedPythonPackages = python-packages; |
||||
} |
||||
); |
||||
in |
||||
(withPackages hyDefinedPythonPackages) // { |
||||
# Export withPackages function for hy customization |
||||
inherit withPackages; |
||||
} |
Loading…
Reference in new issue