diff options
author | Pavol Rusnak <pavol@rusnak.io> | 2021-12-08 23:11:49 +0100 |
---|---|---|
committer | Pavol Rusnak <pavol@rusnak.io> | 2021-12-14 18:53:25 +0100 |
commit | dbf7134d29c504615b31ad5c277bd3ade46684dc (patch) | |
tree | 10856314a81f665f32b1263042b1231220e30400 /pkgs/development/interpreters/python/rustpython | |
parent | 19057428f94082703e442e5476b9f827a856a321 (diff) | |
download | nixlib-dbf7134d29c504615b31ad5c277bd3ade46684dc.tar nixlib-dbf7134d29c504615b31ad5c277bd3ade46684dc.tar.gz nixlib-dbf7134d29c504615b31ad5c277bd3ade46684dc.tar.bz2 nixlib-dbf7134d29c504615b31ad5c277bd3ade46684dc.tar.lz nixlib-dbf7134d29c504615b31ad5c277bd3ade46684dc.tar.xz nixlib-dbf7134d29c504615b31ad5c277bd3ade46684dc.tar.zst nixlib-dbf7134d29c504615b31ad5c277bd3ade46684dc.zip |
rustpython: init at unstable-2021-12-09
Diffstat (limited to 'pkgs/development/interpreters/python/rustpython')
-rw-r--r-- | pkgs/development/interpreters/python/rustpython/default.nix | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/pkgs/development/interpreters/python/rustpython/default.nix b/pkgs/development/interpreters/python/rustpython/default.nix new file mode 100644 index 000000000000..ad4382203223 --- /dev/null +++ b/pkgs/development/interpreters/python/rustpython/default.nix @@ -0,0 +1,44 @@ +{ lib +, stdenv +, rustPlatform +, fetchFromGitHub +, SystemConfiguration +, python3 +}: + +rustPlatform.buildRustPackage rec { + pname = "rustpython"; + version = "unstable-2021-12-09"; + + src = fetchFromGitHub { + owner = "RustPython"; + repo = "RustPython"; + rev = "db3b3127df34ff5dd569301aa36ed71ae5624e4e"; + sha256 = "sha256-YwGfXs3A5L/18mHnnWubPU3Y8EI9uU3keJ2HJnnTwv0="; + }; + + cargoHash = "sha256-T85kiPG80oZ4mwpb8Ag40wDHKx2Aens+gM7NGXan5lM="; + + # freeze the stdlib into the rustpython binary + cargoBuildFlags = "--features=freeze-stdlib"; + + buildInputs = lib.optionals stdenv.isDarwin [ SystemConfiguration ]; + + checkInputs = [ python3 ]; + + meta = with lib; { + description = "Python 3 interpreter in written Rust"; + homepage = "https://rustpython.github.io"; + license = licenses.mit; + maintainers = with maintainers; [ prusnak ]; + + # TODO: Remove once nixpkgs uses newer SDKs that supports '*at' functions. + # Probably macOS SDK 10.13 or later. Check the current version in + # .../os-specific/darwin/apple-sdk/default.nix + # + # From the build logs: + # + # > Undefined symbols for architecture x86_64: "_utimensat" + broken = stdenv.isDarwin && stdenv.isx86_64; + }; +} |