anchor.diff:    # also other parts than "libs" need this statically linked lib
     makeInternalLib = "(cd dbus && make libdbus-internal.la)";
   
  -  systemdOrEmpty = stdenv.lib.optional stdenv.isLinux systemd;
  +  systemdOrEmpty = lib.optional stdenv.isLinux systemd;
   
     # A generic builder for individual parts (subdirs) of D-Bus
     dbus_drv = name: subdirs: merge: stdenv.mkDerivation (lib.mergeAttrsByFuncDefaultsClean [{
  
positive.code:     configureFlags = [ "--with-dbus-daemondir=${daemon}/bin" ];
      buildInputs = buildInputsX ++ systemdOrEmpty ++ [ libs daemon dbus_glib ];
      NIX_CFLAGS_LINK = "-Wl,--as-needed -ldbus-1";
    };
  
    daemon = dbus_drv "daemon" "bus" {
  
negative.code: 
      doCheck = true;
  
      patches = [ ./ignore-missing-includedirs.patch ]
        ++ lib.optional (stdenv.isSunOS || stdenv.isLinux/*avoid rebuilds*/) ./implement-getgrouplist.patch
        ++ [ ./ucred-dirty-hack.patch ./no-create-dirs.patch ];
  
      nativeBuildInputs = [ pkgconfig ];
      propagatedBuildInputs = [ expat ];
  