diff options
author | OTABI Tomoya <tomoya.otabi@gmail.com> | 2023-08-12 09:56:04 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-12 09:56:04 +0900 |
commit | 41d65e418b9875cb6cae474ba3dd4ce854f1e0ed (patch) | |
tree | 900a02f1a72bcd6a4da7574720e60243f2981a15 /pkgs/development | |
parent | c94124e38e42c9c7ef3bb72c0d715dd47cd08eb7 (diff) | |
parent | be02ea8a60fb16a3f49707fc0aa93f659a5fca37 (diff) |
Merge pull request #248562 from figsoda/gpython
gpython: init at 0.2.0
Diffstat (limited to 'pkgs/development')
-rw-r--r-- | pkgs/development/interpreters/gpython/default.nix | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/pkgs/development/interpreters/gpython/default.nix b/pkgs/development/interpreters/gpython/default.nix new file mode 100644 index 0000000000000..8bb432e839ea6 --- /dev/null +++ b/pkgs/development/interpreters/gpython/default.nix @@ -0,0 +1,47 @@ +{ lib +, buildGoModule +, fetchFromGitHub +, testers +, gpython +}: + +buildGoModule rec { + pname = "gpython"; + version = "0.2.0"; + + src = fetchFromGitHub { + owner = "go-python"; + repo = "gpython"; + rev = "v${version}"; + hash = "sha256-xqwq27u41Jgoh7t9UDyatuBQswr+h3xio5AV/npncHc="; + }; + + vendorHash = "sha256-NXPllEhootdB8m5Wvfy8MW899oQnjWAQj7yCC2oDvqE="; + + subPackages = [ + "." + ]; + + ldflags = [ + "-s" + "-w" + "-X=main.version=${version}" + "-X=main.commit=${src.rev}" + "-X=main.date=1970-01-01" + ]; + + passthru.tests = { + version = testers.testVersion { + package = gpython; + command = "gpython < /dev/null"; + }; + }; + + meta = with lib; { + description = "A Python interpreter written in Go"; + homepage = "https://github.com/go-python/gpython"; + changelog = "https://github.com/go-python/gpython/releases/tag/${src.rev}"; + license = licenses.bsd3; + maintainers = with maintainers; [ figsoda ]; + }; +} |