20030dc8d5
ysyx_22040000 李心杨 Linux calcite 6.6.19 #1-NixOS SMP PREEMPT_DYNAMIC Fri Mar 1 12:35:11 UTC 2024 x86_64 GNU/Linux 01:03:00 up 10:38, 2 users, load average: 0.20, 0.16, 0.66
26 lines
414 B
Nix
26 lines
414 B
Nix
{ stdenv,
|
|
lib,
|
|
cmake,
|
|
SDL2,
|
|
isa ? "native",
|
|
platform ? "NEMU"
|
|
}:
|
|
stdenv.mkDerivation {
|
|
pname = "abstract-machine";
|
|
version = "2024.02.18";
|
|
|
|
src = ./.;
|
|
|
|
cmakeFlags = [
|
|
(lib.cmakeFeature "ISA" isa)
|
|
(lib.cmakeBool "__PLATFORM_${lib.strings.toUpper platform}__" true)
|
|
];
|
|
|
|
nativeBuildInputs = [
|
|
cmake
|
|
];
|
|
|
|
buildInputs = [
|
|
|
|
] ++ (if platform=="native" then [ SDL2 ] else [ ]);
|
|
}
|