lol
1{
2 lib,
3 stdenv,
4 mkDerivation,
5 fetchFromGitHub,
6 cmake,
7 fuse,
8 readline,
9 pkg-config,
10 qtbase,
11 qttools,
12 wrapQtAppsHook,
13}:
14
15mkDerivation rec {
16 pname = "android-file-transfer";
17 version = "4.4";
18
19 src = fetchFromGitHub {
20 owner = "whoozle";
21 repo = "android-file-transfer-linux";
22 rev = "v${version}";
23 sha256 = "sha256-1euoWM9KMauOkAp7g1FvY4olMiOg+La/Uk1QlQ3mKi8=";
24 };
25
26 patches = [ ./darwin-dont-vendor-dependencies.patch ];
27
28 nativeBuildInputs = [
29 cmake
30 readline
31 pkg-config
32 wrapQtAppsHook
33 ];
34 buildInputs = [
35 fuse
36 qtbase
37 qttools
38 ];
39
40 postInstall = lib.optionalString stdenv.hostPlatform.isDarwin ''
41 mkdir $out/Applications
42 mv $out/*.app $out/Applications
43 '';
44
45 meta = with lib; {
46 description = "Reliable MTP client with minimalistic UI";
47 homepage = "https://whoozle.github.io/android-file-transfer-linux/";
48 license = licenses.lgpl21Plus;
49 maintainers = [ maintainers.xaverdh ];
50 platforms = platforms.unix;
51 };
52}