1{ lib, stdenv
2, buildPythonPackage
3, fetchFromGitHub
4, vmprof
5, isPyPy
6, pkgs
7, scons
8, chrpath
9}:
10
11buildPythonPackage rec {
12 pname = "nuitka";
13 version = "1.1.5";
14 format = "setuptools";
15
16 src = fetchFromGitHub {
17 owner = "Nuitka";
18 repo = "Nuitka";
19 rev = version;
20 hash = "sha256-8eWOcxATVS866nlN39b2VU1CuXAfcn0yQsDweHS2yDU=";
21 };
22
23 nativeCheckInputs = [ vmprof ];
24 nativeBuildInputs = [ scons ];
25 propagatedBuildInputs = [ chrpath ];
26
27 postPatch = ''
28 patchShebangs tests/run-tests
29 '' + lib.optionalString stdenv.isLinux ''
30 substituteInPlace nuitka/plugins/standard/ImplicitImports.py --replace 'locateDLL("uuid")' '"${lib.getLib pkgs.util-linux}/lib/libuuid.so"'
31 '';
32
33 # We do not want any wrappers here.
34 postFixup = "";
35
36 checkPhase = ''
37 tests/run-tests
38 '';
39
40 # Problem with a subprocess (parts)
41 doCheck = false;
42
43 # Requires CPython
44 disabled = isPyPy;
45
46 meta = with lib; {
47 description = "Python compiler with full language support and CPython compatibility";
48 license = licenses.asl20;
49 homepage = "https://nuitka.net/";
50 };
51
52}