{
  config,
  lib,
  pkgs,
  ...
}:

{
  imports = [ ];

  options.me = {
    amd_s2idle.enable = lib.mkOption {
      type = lib.types.bool;
      default = false;
      example = true;
      description = "Whether we want to install amd_s2idle.";
    };
  };

  config = lib.mkIf config.me.amd_s2idle.enable {
    environment.systemPackages = with pkgs; [
      amd-debug-tools
    ];
    nixpkgs.overlays = [
      (
        final: prev:
        let
          innerPackage = (final.callPackage ./package.nix { });
        in
        {
          amd-debug-tools = innerPackage;
        }
      )
      (final: prev: {
        pythonPackagesExtensions = prev.pythonPackagesExtensions ++ [
          (python-final: python-prev: {
            cysystemd = (python-final.callPackage ./cysystemd.nix { });
          })
        ];
      })
    ];
  };
}
