7 stdenvNoCC.mkDerivation {
8 name = "amd-ucodegen-test-platomav";
11 # Repository of dumped CPU microcodes
12 src = fetchFromGitHub {
14 repo = "CPUMicrocodes";
15 rev = "dfc37d654cbe294acb0ec0274763321507dd7838";
16 hash = "sha256-Va+ErKID5iyKEee61tlrZwSpujxwMYPC+MAgZKUkrrM=";
19 nativeBuildInputs = [ amd-ucodegen ];
23 echo -n "Test normal behavior with single input... "
24 [ "$(amd-ucodegen AMD/cpu00B40F40_ver0B40401A_2024-06-14_544DFCB8.bin)" \
25 == "CPU type 0xb40f40 [0xb440], file AMD/cpu00B40F40_ver0B40401A_2024-06-14_544DFCB8.bin" ]
27 echo -n "Check output hash... "
28 [ "$(sha256sum microcode_amd_fam1ah.bin)" \
29 == "17f25ec78fa677803684e77ce01a21344b4b33463a964f61bae51b173543b190 microcode_amd_fam1ah.bin" ]
31 echo -n "Ensure fail when bad processor ID... "
32 [ "$(amd-ucodegen AMD/cpu00000F00_ver02000008_2007-06-14_C3A923BB.bin 2>&1)" \
33 == "Bad processor ID 0x0n" ]