anchor.diff:  
     nativeBuildInputs = [ cmake pkg-config ];
   
  -  buildInputs = [ libva libpciaccess intel-gmmlib libX11 ];
  +  buildInputs = [ libva libpciaccess intel-gmmlib ]
  +    ++ stdenv.lib.optional enableX11 libX11;
   
     meta = with stdenv.lib; {
       description = "Intel Media Driver for VAAPI — Broadwell+ iGPUs";
  
positive.code: { stdenv, fetchFromGitHub
  , cmake, pkg-config
  , libva, libpciaccess, intel-gmmlib, libX11
  }:
  
  stdenv.mkDerivation rec {
  
negative.code:     platforms = platforms.linux;
      maintainers = with maintainers; [ primeos jfrankenau ];
    };
  
    postFixup = stdenv.lib.optionalString enableX11 ''
      patchelf --set-rpath "$(patchelf --print-rpath $out/lib/dri/iHD_drv_video.so):${stdenv.lib.makeLibraryPath [ libX11  ]}" \
        $out/lib/dri/iHD_drv_video.so
    '';
  }
  