brainix/nix/brain-kernel.nix
2026-02-13 17:06:24 +09:00

21 lines
649 B
Nix

{ pkgs }:
let
src = builtins.path {
path = ../sources/linux-brain-brain;
name = "linux-brain";
};
version = "5.4.149";
in pkgs.callPackage (pkgs.path + "/pkgs/os-specific/linux/kernel/generic.nix") {
# Match licheepi4a approach: use an older GCC stdenv for the kernel build.
# GCC 14 emits __aeabi_uldivmod for 64-bit divides in blk-iocost on ARMv5,
# and the kernel does not link libgcc. GCC 13 avoids this.
stdenv = pkgs.gcc13Stdenv;
} {
inherit src version;
modDirVersion = version;
defconfig = "brain_defconfig";
kernelPatches = [];
extraMeta = {
description = "Linux kernel for SHARP Brain (i.MX28)";
};
}