nixpkgs/pkgs/development/tools/garble/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

36 lines
895 B
Nix
Raw Normal View History

2021-02-20 01:45:04 +00:00
{ stdenv
, buildGoModule
2021-02-10 08:22:57 +00:00
, fetchFromGitHub
, lib
, git
2021-02-10 08:22:57 +00:00
}:
buildGoModule rec {
pname = "garble";
2022-12-17 08:12:07 +00:00
version = "0.8.0";
2021-02-10 08:22:57 +00:00
src = fetchFromGitHub {
owner = "burrowers";
repo = pname;
rev = "v${version}";
2022-12-17 08:12:07 +00:00
sha256 = "sha256-f7coWG1CS4UL8GGqwADx5CvIk2sPONPlWW+JgRhFsb8=";
2021-02-10 08:22:57 +00:00
};
vendorHash = "sha256-SOdIlu0QrQokl9j9Ff594+1K6twU1mCuECFQaVKaPV4=";
2021-02-10 08:22:57 +00:00
# Used for some of the tests.
nativeCheckInputs = [git];
preBuild = lib.optionalString (!stdenv.isx86_64) ''
2021-02-20 01:45:04 +00:00
# The test assumex amd64 assembly
rm testdata/script/asm.txtar
2021-02-20 01:45:04 +00:00
'';
2021-02-10 08:22:57 +00:00
meta = {
description = "Obfuscate Go code by wrapping the Go toolchain";
homepage = "https://github.com/burrowers/garble/";
maintainers = with lib.maintainers; [ davhau ];
license = lib.licenses.bsd3;
2022-01-03 23:53:54 +00:00
broken = stdenv.isDarwin; # never built on Hydra https://hydra.nixos.org/job/nixpkgs/trunk/garble.x86_64-darwin
2021-02-10 08:22:57 +00:00
};
}