anchor.diff:  
     config = mkIf config.hardware.sane.enable {
   
  -    environment.systemPackages = [ pkg ];
  -    services.udev.packages = [ pkg ];
  +    environment.systemPackages = backends;
  +    environment.variables = {
  +      SANE_CONFIG_DIR = "${saneConfig}/etc/sane.d";
  +      LD_LIBRARY_PATH = [ "${saneConfig}/lib/sane" ];
  +    };
  +    services.udev.packages = backends;
   
       users.extraGroups."scanner".gid = config.ids.gids.scanner;
   
  
positive.code:       description = "Use a development snapshot of SANE scanner drivers.";
      };
  
    };
  
  
  
negative.code: let
  
    pkg = if config.hardware.sane.snapshot then pkgs.saneBackendsGit else pkgs.saneBackends;
    backends = [ pkg ] ++ config.hardware.sane.extraBackends;
    saneConfig = pkgs.mkSaneConfig { paths = backends; };
  
  in
  
  