anchor.diff: -{ stdenv, fetchurl, unzip, SDL, libjpeg, zlib, libvorbis, curl }:
  +{ stdenv, fetchurl
  +, # required for both
  +  unzip, libjpeg, zlib, libvorbis, curl
  +, # glx
  +  libX11, mesa, libXpm, libXext, libXxf86vm, alsaLib
  +, # sdl
  +  SDL
  +}:
   
   stdenv.mkDerivation rec {
     name = "xonotic-0.7.0";
  
positive.code: 
    buildPhase = ''
      DP_FS_BASEDIR="$out/share/xonotic"
      #make DP_FS_BASEDIR=$DP_FS_BASEDIR cl-release
      make DP_FS_BASEDIR=$DP_FS_BASEDIR sdl-release
      make DP_FS_BASEDIR=$DP_FS_BASEDIR sv-release
    '';
  
negative.code:     mkdir -p "$out/bin"
      cp darkplaces-dedicated "$out/bin/xonotic-dedicated"
      cp darkplaces-sdl "$out/bin/xonotic-sdl"
      cp darkplaces-glx "$out/bin/xonotic-glx"
      cd ../..
      mkdir -p "$out/share/xonotic"
      mv data "$out/share/xonotic"
  
      # default to sdl
      ln -s "$out/bin/xonotic-sdl" "$out/bin/xonotic"
    '';
  
    dontPatchELF = true;
  