02cf88bb76
GitOrigin-RevId: c4a0efdd5a728e20791b8d8d2f26f90ac228ee8d
29 lines
596 B
Nix
29 lines
596 B
Nix
{ config, lib, ... }:
|
|
|
|
with lib;
|
|
|
|
let cfg = config.programs.systemtap;
|
|
in {
|
|
|
|
options = {
|
|
programs.systemtap = {
|
|
enable = mkOption {
|
|
type = types.bool;
|
|
default = false;
|
|
description = lib.mdDoc ''
|
|
Install {command}`systemtap` along with necessary kernel options.
|
|
'';
|
|
};
|
|
};
|
|
};
|
|
config = mkIf cfg.enable {
|
|
system.requiredKernelConfig = with config.lib.kernelConfig; [
|
|
(isYes "DEBUG")
|
|
];
|
|
boot.kernel.features.debug = true;
|
|
environment.systemPackages = [
|
|
config.boot.kernelPackages.systemtap
|
|
];
|
|
};
|
|
|
|
}
|