From c733ae88f30f62cf018c1ffcea2457168dbf5f58 Mon Sep 17 00:00:00 2001 From: Bailey Stevens Date: Wed, 20 Sep 2023 18:53:36 -0400 Subject: [PATCH] RasPi 4 kernel build fixes. Overlay from https://github.com/NixOS/nixpkgs/issues/154163#issuecomment-1350599022 Disables ZFS to avoid rebuilding the kernel. --- flake.nix | 6 ++++++ platforms/orange.nix | 8 +++++--- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/flake.nix b/flake.nix index 2bfeb48..163576d 100644 --- a/flake.nix +++ b/flake.nix @@ -39,6 +39,12 @@ # Target device (RPi3 aarch64) nixpkgs. pkgs = import nixpkgs { system = "aarch64-linux"; + overlays = [ + (final: super: { + makeModulesClosure = x: + super.makeModulesClosure (x // { allowMissing = true; }); + }) + ]; }; # Modules for colmena and sd card image are the same. modules = [ diff --git a/platforms/orange.nix b/platforms/orange.nix index 1ab1c56..e530c52 100644 --- a/platforms/orange.nix +++ b/platforms/orange.nix @@ -1,14 +1,16 @@ -{pkgs, ...}: +{pkgs, lib, ...}: { nixpkgs.hostPlatform.system = "aarch64-linux"; sdImage.imageName = "orange.img"; boot.loader.raspberryPi.version = 4; + boot.supportedFilesystems = lib.mkForce [ "btrfs" "cifs" "f2fs" "jfs" "ntfs" "reiserfs" "vfat" "xfs" ]; hardware.raspberry-pi."4" = { - fkms-3d.enable = true; - apply-overlays-dtmerge.enable = true; + fkms-3d.enable = true; + apply-overlays-dtmerge.enable = true; }; + console.enable = false; environment.systemPackages = with pkgs; [ libraspberrypi