2021-01-04 09:44:04 +00:00
|
|
|
{ lib
|
|
|
|
, rustPlatform
|
|
|
|
, fetchFromGitHub
|
|
|
|
, buildPythonPackage
|
|
|
|
}:
|
|
|
|
let
|
|
|
|
pname = "wasmer";
|
2021-01-24 09:32:28 +00:00
|
|
|
version = "1.0.0";
|
2021-02-11 18:30:30 +00:00
|
|
|
in buildPythonPackage rec {
|
|
|
|
inherit pname version;
|
2021-01-04 09:44:04 +00:00
|
|
|
|
2021-02-11 18:30:30 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "wasmerio";
|
|
|
|
repo = "wasmer-python";
|
|
|
|
rev = version;
|
|
|
|
hash = "sha256-I1GfjLaPYMIHKh2m/5IQepUsJNiVUEJg49wyuuzUYtY=";
|
|
|
|
};
|
2021-01-04 09:44:04 +00:00
|
|
|
|
2021-02-11 18:30:30 +00:00
|
|
|
cargoDeps = rustPlatform.fetchCargoTarball {
|
|
|
|
inherit src;
|
|
|
|
name = "${pname}-${version}";
|
|
|
|
hash = "sha256-txOOia1C4W+nsXuXp4EytEn82CFfSmiOYwRLC4WPImc=";
|
2021-01-04 09:44:04 +00:00
|
|
|
};
|
|
|
|
|
2021-02-11 18:30:30 +00:00
|
|
|
format = "pyproject";
|
|
|
|
|
|
|
|
nativeBuildInputs = with rustPlatform; [ cargoSetupHook maturinBuildHook ];
|
2021-01-04 09:44:04 +00:00
|
|
|
|
2021-02-11 18:30:30 +00:00
|
|
|
buildAndTestSubdir = "packages/api";
|
2021-01-04 09:44:04 +00:00
|
|
|
|
2021-02-11 18:30:30 +00:00
|
|
|
doCheck = false;
|
2021-01-04 09:44:04 +00:00
|
|
|
|
|
|
|
pythonImportsCheck = [ "wasmer" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python extension to run WebAssembly binaries";
|
|
|
|
homepage = "https://github.com/wasmerio/wasmer-python";
|
|
|
|
license = licenses.mit;
|
2021-04-01 08:16:32 +00:00
|
|
|
platforms = platforms.unix;
|
2021-01-04 09:44:04 +00:00
|
|
|
maintainers = with maintainers; [ SuperSandro2000 ];
|
|
|
|
};
|
|
|
|
}
|