1
0
Fork 0
mirror of https://github.com/NixOS/nixos-hardware synced 2024-12-27 20:19:45 +01:00
nixos-hardware/microchip/common/bsp/hss-payload-generator.nix
Ganga Ram ba8b9209ce Add Microchip Icicle-kit board support.
* Uses Linux kernel released by Microchip
  - https://github.com/linux4microchip/linux.git
  - Ver: v5.15   Tag: linux4microchip+fpga-2023.02
* Uses UBoot released by Microchip
  - Ver: uboot-2022-01 Tag: linux4microchip+fpga-2023.02

To generate NixOS sd image for MICROCHIP icicle-kit refer:
  https://github.com/tiiuae/ghaf.git

Signed-off-by: Ganga Ram <Ganga.Ram@tii.ae>
2023-04-26 22:55:57 +04:00

50 lines
870 B
Nix

{ pkgs, ...}:
with pkgs;
stdenv.mkDerivation rec {
pname = "hss";
version = "v2022.09";
src = fetchFromGitHub {
owner = "polarfire-soc";
repo = "hart-software-services";
rev = version;
sha256 = "sha256-j/nda7//CjJW09zt/YrBy6h+q+VKE5t/ueXxDzwVWQ0=";
};
depsBuildBuild = [
buildPackages.stdenv.cc
];
nativeBuildInputs = with buildPackages; [
libyaml
elfutils
openssl
zlib
];
patchPhase = ''
runHook prePatch
substituteInPlace ./tools/hss-payload-generator/Makefile \
--replace "/bin/bash" "bash"
runHook postPatch
'';
buildPhase = ''
runHook preBuild
make -C ./tools/hss-payload-generator
runHook postBuild
'';
installPhase = ''
runHook preInstall
mkdir -p $out
cp ./tools/hss-payload-generator/hss-payload-generator $out
runHook postConfigure
'';
}