anchor.diff:      libxext
       libxrandr
       libxv
  +    openssl
       procps
       systemd_lib
       xorgproto
  
positive.code: { stdenv
  , bison
  , fetchurl
  , flex
  , lib
  
negative.code:   ];
  
    postPatch = ''
      # Don't build benchmarks
      grep -q "subdir('benchmarks')" meson.build
      sed -i "/subdir('benchmarks')/d" meson.build
  
      # Fix build impurities
      grep -q 'IGT_SRCDIR' lib/igt_core.h
      sed -i 's,IGT_SRCDIR,"/no-such-path",g' lib/igt_core.h
  
      # Fix name of rst2man executable
      grep -q "'rst2man'" man/meson.build
      sed -i "s#'rst2man'#'rst2man.py'#" man/meson.build
      grep -q '^rst2man ' man/rst2man.sh
      sed -i 's#^rst2man #rst2man.py #' man/rst2man.sh
  
      patchShebangs man/rst2man.sh
    '';
  
    mesonFlags = [
      "-Dbuild_tests=false"
      "-Dbuild_man=true"
      "-Dbuild_docs=false"
      "-Duse-rpath=true"
    ];
  
  