2022-01-13 20:06:32 +00:00
|
|
|
{ stdenv, lib, fetchFromGitHub, kernel }:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2023-03-15 16:39:30 +00:00
|
|
|
pname = "vmm_clock";
|
2023-02-02 18:25:31 +00:00
|
|
|
version = "0.2.0";
|
2022-01-13 20:06:32 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "voutilad";
|
|
|
|
repo = "vmm_clock";
|
2023-07-15 17:15:38 +00:00
|
|
|
rev = version;
|
2023-02-02 18:25:31 +00:00
|
|
|
hash = "sha256-8z/N/dbkeFd40sH7jatNmSS62B88tC0jVgNljhxslOo=";
|
2022-01-13 20:06:32 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
hardeningDisable = [ "pic" "format" ];
|
|
|
|
nativeBuildInputs = kernel.moduleBuildDependencies;
|
|
|
|
|
|
|
|
extraConfig = ''
|
|
|
|
CONFIG_RTC_HCTOSYS yes
|
|
|
|
'';
|
|
|
|
|
|
|
|
makeFlags = kernel.makeFlags ++ [
|
|
|
|
"DEPMOD=echo"
|
|
|
|
"INSTALL_MOD_PATH=$(out)"
|
|
|
|
"KERNELRELEASE=${kernel.modDirVersion}"
|
|
|
|
"KERNELDIR=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build"
|
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description =
|
|
|
|
"Experimental implementation of a kvmclock-derived clocksource for Linux guests under OpenBSD's hypervisor";
|
|
|
|
homepage = "https://github.com/voutilad/vmm_clock";
|
|
|
|
license = licenses.gpl2;
|
|
|
|
maintainers = with maintainers; [ qbit ];
|
2022-11-21 17:40:18 +00:00
|
|
|
platforms = [ "i686-linux" "x86_64-linux" ];
|
2022-01-13 20:06:32 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
}
|