2023-11-16 04:20:00 +00:00
|
|
|
{ lib
|
2020-04-24 23:36:52 +00:00
|
|
|
, buildPythonPackage
|
2023-11-16 04:20:00 +00:00
|
|
|
, ccache
|
2021-05-03 20:48:10 +00:00
|
|
|
, fetchFromGitHub
|
2020-04-24 23:36:52 +00:00
|
|
|
, isPyPy
|
2023-11-16 04:20:00 +00:00
|
|
|
, ordered-set
|
|
|
|
, python3
|
|
|
|
, setuptools
|
|
|
|
, zstandard
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
2021-05-03 20:48:10 +00:00
|
|
|
buildPythonPackage rec {
|
2023-03-15 16:39:30 +00:00
|
|
|
pname = "nuitka";
|
2023-11-16 04:20:00 +00:00
|
|
|
version = "1.8.4";
|
|
|
|
pyproject = true;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-05-03 20:48:10 +00:00
|
|
|
src = fetchFromGitHub {
|
2022-10-21 18:38:19 +00:00
|
|
|
owner = "Nuitka";
|
2021-05-03 20:48:10 +00:00
|
|
|
repo = "Nuitka";
|
|
|
|
rev = version;
|
2023-11-16 04:20:00 +00:00
|
|
|
hash = "sha256-spa3V9KEjqmwnHSuxLLIu9hJk5PrRwNyOw72sfxBVKo=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
# default lto off for darwin
|
|
|
|
patches = [ ./darwin-lto.patch ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
nativeBuildInputs = [ setuptools ];
|
|
|
|
nativeCheckInputs = [ ccache ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
ordered-set
|
|
|
|
zstandard
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
checkPhase = ''
|
2023-11-16 04:20:00 +00:00
|
|
|
runHook preCheck
|
|
|
|
|
|
|
|
${python3.interpreter} tests/basics/run_all.py search
|
|
|
|
|
|
|
|
runHook postCheck
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
pythonImportsCheck = [ "nuitka" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
# Requires CPython
|
|
|
|
disabled = isPyPy;
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Python compiler with full language support and CPython compatibility";
|
|
|
|
license = licenses.asl20;
|
|
|
|
homepage = "https://nuitka.net/";
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|