8ac5e011d6
GitOrigin-RevId: 2c3273caa153ee8eb5786bc8141b85b859e7efd7
19 lines
652 B
Nix
19 lines
652 B
Nix
{deployAndroidPackage, lib, package, os, autoPatchelfHook, pkgs}:
|
|
|
|
deployAndroidPackage {
|
|
inherit package os;
|
|
buildInputs = [ autoPatchelfHook ]
|
|
++ lib.optionals (os == "linux") [ pkgs.glibc pkgs.zlib pkgs.ncurses5 ];
|
|
patchInstructions = lib.optionalString (os == "linux") ''
|
|
addAutoPatchelfSearchPath $packageBaseDir/lib64
|
|
autoPatchelf --no-recurse $packageBaseDir/lib64
|
|
autoPatchelf --no-recurse $packageBaseDir
|
|
'' + ''
|
|
mkdir -p $out/bin
|
|
cd $out/bin
|
|
find $out/libexec/android-sdk/platform-tools -type f -executable -mindepth 1 -maxdepth 1 -not -name sqlite3 | while read i
|
|
do
|
|
ln -s $i
|
|
done
|
|
'';
|
|
}
|