depot/third_party/nixpkgs/pkgs/development/python-modules/skytemple-rust/default.nix
Default email 5e7c2d6cef Project import generated by Copybara.
GitOrigin-RevId: f99e5f03cc0aa231ab5950a15ed02afec45ed51a
2023-10-09 21:29:22 +02:00

46 lines
1.1 KiB
Nix

{ lib
, stdenv
, buildPythonPackage
, cargo
, fetchFromGitHub
, libiconv
, Foundation
, rustPlatform
, rustc
, setuptools-rust
, range-typed-integers
}:
buildPythonPackage rec {
pname = "skytemple-rust";
version = "1.5.3";
src = fetchFromGitHub {
owner = "SkyTemple";
repo = pname;
rev = version;
hash = "sha256-Txx8kQNb3ODbaJXfuHERzPx4zGUqYXzy+jbLNaMyf+w=";
};
cargoDeps = rustPlatform.fetchCargoTarball {
inherit src;
name = "${pname}-${version}";
hash = "sha256-KQA8dfHnuysx9EUySJXZ/52Hfq6AbALwkBp3B1WJJuc=";
};
buildInputs = lib.optionals stdenv.isDarwin [ libiconv Foundation ];
nativeBuildInputs = [ setuptools-rust rustPlatform.cargoSetupHook cargo rustc ];
propagatedBuildInputs = [ range-typed-integers ];
GETTEXT_SYSTEM = true;
doCheck = false; # there are no tests
pythonImportsCheck = [ "skytemple_rust" ];
meta = with lib; {
homepage = "https://github.com/SkyTemple/skytemple-rust";
description = "Binary Rust extensions for SkyTemple";
license = licenses.mit;
maintainers = with maintainers; [ xfix marius851000 ];
};
}