anchor.diff:  , systemd_lib
   , tdb
   , webrtc-audio-processing
  -, xorg
  +, xextproto
   
   , prefix ? ""
   
  
positive.code:   ];
  
    buildInputs = [
      glib
      dbus
      libasyncns
      libcap
      libsndfile
      fftw_single
      tdb
      speexdsp
    ] ++ optionals (!libOnly) [
      alsa-lib
      gtk3
      gconf
      avahi
      jack2_lib
      lirc
      openssl
      soxr
      systemd_lib
      webrtc-audio-processing
      xorg.libX11
      xorg.libxcb
      xorg.libICE
      xorg.libSM
      xorg.libXtst
      xorg.xextproto
      xorg.libXi
      bluez
      sbc
    ];
  
    patches = [
  
negative.code:         -e 's/unique_jhsdjhsdf_string/${resampleMethodString}/'
      '';
  
    preConfigure = /* autoreconf */ ''
      export NOCONFIGURE="yes"
      patchShebangs bootstrap.sh
      ./bootstrap.sh
    '' + /* Move the udev rules under $(prefix). */ ''
      sed -i "src/Makefile.in" \
        -e "s|udevrulesdir[[:blank:]]*=.*$|udevrulesdir = $out/lib/udev/rules.d|g"
    '' + /* don't install proximity-helper as root and setuid */ ''
      sed -i "src/Makefile.in" \
        -e "s|chown root|true |" \
        -e "s|chmod r+s |true |"
    '' + ''
      configureFlagsArray+=(
        "--with-systemduserunitdir=$out/lib/systemd/user"
        "--with-bash-completion-dir=$out/share/bash-completions/completions"
      )
    '';
  
    configureFlags = [
      "--localstatedir=/var"
  