1
1
mirror of https://github.com/NixOS/mobile-nixos.git synced 2024-12-16 03:32:02 +03:00

xiaomi-begonia: Pass postPatch as argument rather than override

This commit is contained in:
Samuel Dionne-Riel 2020-09-30 01:06:51 -04:00
parent 63b1643a0d
commit ad24812595

View File

@ -77,7 +77,14 @@ in
isModular = false;
}).overrideAttrs({ postInstall ? "", postPatch ? [], ... }: {
postPatch = ''
echo ":: Replacing dtc_overaly"
(PS4=" $ "; set -x
rm scripts/dtc/dtc_overlay
cp ${dtc_overlay} scripts/dtc/dtc_overlay
)
'';
}).overrideAttrs({ postInstall ? "", ... }: {
installTargets = [
# uh, things seem screwey with that vendor kernel tree, and dependencies
# are not resolved as expected, so let's ask for the compressed kernel
@ -87,16 +94,7 @@ in
"Image.gz-dtb"
"install"
];
postInstall = postInstall + ''
cp -v "$buildRoot/arch/arm64/boot/Image.gz-dtb" "$out/"
'';
postPatch = postPatch + ''
echo ":: Replacing dtc_overaly"
(PS4=" $ "; set -x
rm scripts/dtc/dtc_overlay
cp ${dtc_overlay} scripts/dtc/dtc_overlay
)
'';
})