2021-12-08 23:11:49 +01:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, rustPlatform
|
|
|
|
, fetchFromGitHub
|
|
|
|
, SystemConfiguration
|
|
|
|
, python3
|
|
|
|
}:
|
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "rustpython";
|
2022-10-11 22:58:41 +02:00
|
|
|
version = "unstable-2022-10-11";
|
2021-12-08 23:11:49 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "RustPython";
|
|
|
|
repo = "RustPython";
|
2022-10-11 22:58:41 +02:00
|
|
|
rev = "273ffd969ca6536df06d9f69076c2badb86f8f8c";
|
|
|
|
sha256 = "sha256-t/3++EeP7a8t2H0IEPLogBri7+6u+2+v+lNb4/Ty1/w=";
|
2021-12-08 23:11:49 +01:00
|
|
|
};
|
|
|
|
|
2022-10-11 22:58:41 +02:00
|
|
|
cargoHash = "sha256-Pv7SK64+eoK1VUxDh1oH0g1veWoIvBhiZE9JI/alXJ4=";
|
2021-12-08 23:11:49 +01:00
|
|
|
|
|
|
|
# freeze the stdlib into the rustpython binary
|
2022-10-03 16:56:51 +03:00
|
|
|
cargoBuildFlags = [ "--features=freeze-stdlib" ];
|
2021-12-08 23:11:49 +01:00
|
|
|
|
|
|
|
buildInputs = lib.optionals stdenv.isDarwin [ SystemConfiguration ];
|
|
|
|
|
2023-01-21 12:00:00 +00:00
|
|
|
nativeCheckInputs = [ python3 ];
|
2021-12-08 23:11:49 +01:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python 3 interpreter in written Rust";
|
|
|
|
homepage = "https://rustpython.github.io";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ prusnak ];
|
|
|
|
};
|
|
|
|
}
|