anchor.diff:    
       services.xserver.displayManager.job =
         { execCmd =
  -          (optionalString (config.system.boot.loader.id == "grub") "PATH=${config.system.build.grub}/sbin:$PATH ") +
  -          "KDEDIRS=${kdebase_workspace} exec ${kdebase_workspace}/bin/kdm -config ${kdmrc} -nodaemon";
  +          ''
  +            mkdir -p /var/lib/kdm
  +            ${(optionalString (config.system.boot.loader.id == "grub") "PATH=${config.system.build.grub}/sbin:$PATH ") +
  +              "KDEDIRS=${kdebase_workspace} exec ${kdebase_workspace}/bin/kdm -config ${kdmrc} -nodaemon"}
  +          '';
           logsXsession = true;
         };
   
  
positive.code: {pkgs, config, ...}:
  
  with pkgs.lib;
  
  
negative.code:       HaltCmd=${config.system.build.upstart}/sbin/halt
        RebootCmd=${config.system.build.upstart}/sbin/reboot
        ${optionalString (config.system.boot.loader.id == "grub") ''
          BootManager=${if config.boot.loader.grub.version == 2 then "Grub2" else "Grub"}
        ''}
  
        [X-*-Core]
  