mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-16 18:03:59 +00:00
c6568adb00
most found with https://github.com/siraben/nix-lint
23 lines
950 B
Nix
23 lines
950 B
Nix
{deployAndroidPackage, lib, package, os, autoPatchelfHook, makeWrapper, pkgs, pkgs_i686}:
|
|
|
|
deployAndroidPackage {
|
|
inherit package os;
|
|
nativeBuildInputs = [ makeWrapper ]
|
|
++ lib.optionals (os == "linux") [ autoPatchelfHook ];
|
|
buildInputs = lib.optionals (os == "linux") [ pkgs.glibc pkgs.zlib pkgs.ncurses5 pkgs_i686.glibc pkgs_i686.zlib pkgs_i686.ncurses5 pkgs.libcxx ];
|
|
patchInstructions = ''
|
|
${lib.optionalString (os == "linux") ''
|
|
addAutoPatchelfSearchPath $packageBaseDir/lib
|
|
if [[ -d $packageBaseDir/lib64 ]]; then
|
|
addAutoPatchelfSearchPath $packageBaseDir/lib64
|
|
autoPatchelf --no-recurse $packageBaseDir/lib64
|
|
fi
|
|
autoPatchelf --no-recurse $packageBaseDir
|
|
''}
|
|
|
|
wrapProgram $PWD/mainDexClasses \
|
|
--prefix PATH : ${pkgs.jdk8}/bin
|
|
'';
|
|
noAuditTmpdir = true; # The checker script gets confused by the build-tools path that is incorrectly identified as a reference to /build
|
|
}
|