1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-25 15:11:35 +00:00

Merge pull request #26949 from Profpatsch/adbfs-rootless

adbfs-rootless: init at 2016-10-02
This commit is contained in:
Jörg Thalheim 2017-06-29 08:22:42 +01:00 committed by GitHub
commit e5eccf311f
2 changed files with 45 additions and 0 deletions

View file

@ -0,0 +1,41 @@
{ stdenv, fetchFromGitHub, fetchpatch, pkgconfig, fuse, adb }:
stdenv.mkDerivation rec {
name = "adbfs-rootless-${version}";
version = "2016-10-02";
src = fetchFromGitHub {
owner = "spion";
repo = "adbfs-rootless";
rev = "b58963430e40c9246710a16cec58e7ffc88baa48";
sha256 = "1kjibl86k6pf7vciwaaxwv5m4q28zdpd2g7yhp71av32jq6j3wm8";
};
patches = [
(fetchpatch {
# https://github.com/spion/adbfs-rootless/issues/14
url = "https://github.com/kronenpj/adbfs-rootless/commit/35f87ce0a7aeddaaad118daed3022e01453b838d.patch";
sha256 = "1iigla74n3hphnyx9ffli9wqk7v71ylvsxama868czlg7851jqj9";
})
];
buildInputs = [ fuse pkgconfig ];
postPatch = ''
# very ugly way of replacing the adb calls
sed -e 's|"adb |"${stdenv.lib.getBin adb}/bin/adb |g' \
-i adbfs.cpp
'';
installPhase = ''
install -D adbfs $out/bin/adbfs
'';
meta = with stdenv.lib; {
description = "Mount Android phones on Linux with adb, no root required";
inherit (src.meta) homepage;
license = licenses.bsd3;
maintainers = with maintainers; [ profpatsch ];
platforms = platforms.linux;
};
}

View file

@ -579,6 +579,10 @@ with pkgs;
pkgs_i686 = pkgsi686Linux;
};
adbfs-rootless = callPackage ../development/mobile/adbfs-rootless {
adb = androidenv.platformTools;
};
adb-sync = callPackage ../development/mobile/adb-sync { };
androidenv = callPackage ../development/mobile/androidenv {