1
0
Fork 0

flake: fix not-os

Signed-off-by: Florian Agbuya <fa@m-labs.ph>
This commit is contained in:
Florian Agbuya 2023-11-30 12:17:23 +08:00
parent ba3934bb06
commit 0f1acb3e10
1 changed files with 18 additions and 3 deletions

View File

@ -4,10 +4,21 @@
inputs.nixpkgs.url = github:NixOS/nixpkgs/nixos-unstable;
inputs.not-os.url = github:cleverca22/not-os;
inputs.not-os.inputs.nixpkgs.follows = "nixpkgs";
outputs = { self, nixpkgs, not-os }:
let
pkgs = import nixpkgs { system = "x86_64-linux"; };
not-os-patches = [
{
url = "https://patch-diff.githubusercontent.com/raw/cleverca22/not-os/pull/25.patch";
sha256 = "0cca105sidviariwpj2hy72c6yjrcv4m4pzjmvmmp9fkcv2pi3aa";
}
];
patched-not-os = pkgs.applyPatches {
name = "not-os-patched";
src = not-os;
patches = map pkgs.fetchpatch not-os-patches;
};
gnu-platform = "arm-none-eabi";
@ -207,10 +218,10 @@
echo file binary-dist $out/boot.bin >> $out/nix-support/hydra-build-products
'';
not-os-configured = (import "${not-os}" {
not-os-configured = (import patched-not-os {
inherit nixpkgs;
extraModules = [
"${not-os}/zynq_image.nix"
"${patched-not-os}/zynq_image.nix"
];
platform = system: (import nixpkgs { config = {}; }).platforms.armv7l-hf-multiplatform;
system = "x86_64-linux";
@ -227,4 +238,8 @@
zc706-not-os = not-os-configured.config.system.build.zynq_image;
};
};
nixConfig = {
allow-import-from-derivation = true;
};
}