nixpkgs/pkgs/by-name/go/go-mtpfs/package.nix

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

36 lines
939 B
Nix
Raw Normal View History

2022-11-11 08:15:13 +00:00
{ lib, stdenv, buildGoModule, fetchFromGitHub, pkg-config, libusb1 }:
2016-06-03 11:50:07 +00:00
2022-05-03 01:39:23 +00:00
buildGoModule rec {
pname = "go-mtpfs";
2022-05-03 01:39:23 +00:00
version = "1.0.0";
2016-06-03 11:50:07 +00:00
2022-03-08 14:28:47 +00:00
src = fetchFromGitHub {
owner = "hanwen";
repo = "go-mtpfs";
2022-05-03 01:39:23 +00:00
rev = "v${version}";
2023-01-24 12:55:52 +00:00
hash = "sha256-HVfB8/MImgZZLx4tcrlYOfQjpAdHMHshEaSsd+n758w=";
2022-03-08 14:28:47 +00:00
};
2023-01-24 12:55:52 +00:00
vendorHash = "sha256-OrAEvD2rF0Y0bvCD9TUv/E429lASsvC3uK3qNvbg734=";
2022-05-03 01:39:23 +00:00
ldflags = [ "-s" "-w" ];
nativeBuildInputs = [ pkg-config ];
2016-06-03 11:50:07 +00:00
buildInputs = [ libusb1 ];
checkFlags = [
# Only run tests under mtp/encoding_test.go
# Other tests require an Android deviced attached over USB.
"-run=Test(Encode|Decode|Variant)"
];
2022-05-03 01:39:23 +00:00
meta = with lib; {
description = "Simple FUSE filesystem for mounting Android devices as a MTP device";
homepage = "https://github.com/hanwen/go-mtpfs";
license = licenses.bsd3;
maintainers = [ ];
2022-11-11 08:15:13 +00:00
broken = stdenv.hostPlatform.isDarwin;
2023-11-23 21:09:35 +00:00
mainProgram = "go-mtpfs";
2022-05-03 01:39:23 +00:00
};
2016-06-03 11:50:07 +00:00
}