anchor.diff:          --replace 'usr/share/zoneinfo' 'etc/zoneinfo'
         substituteInPlace tools/depends/target/ffmpeg/autobuild.sh \
           --replace "/bin/bash" "${bash}/bin/bash -ex"
  -      cp ${ffmpeg_2_8_6} tools/depends/target/ffmpeg/ffmpeg-2.8.6-${rel}-16.0.tar.gz
  +      cp ${ffmpeg_3_1_6} tools/depends/target/ffmpeg/ffmpeg-3.1.6-${rel}.tar.gz
  +      ln -s ${libdvdcss.src} tools/depends/target/libdvdcss/libdvdcss-master.tar.gz
  +      ln -s ${libdvdnav.src} tools/depends/target/libdvdnav/libdvdnav-master.tar.gz
  +      ln -s ${libdvdread.src} tools/depends/target/libdvdread/libdvdread-master.tar.gz
       '';
   
       preConfigure = ''
  
positive.code: { stdenv, lib, fetchurl, makeWrapper
  , pkgconfig, cmake, gnumake, yasm, python2
  , boost, avahi, libdvdcss, lame, autoreconfHook
  , gettext, pcre-cpp, yajl, fribidi, which
  , openssl, gperf, tinyxml2, taglib, libssh, swig, jre
  , libX11, xproto, inputproto, libxml2
  
negative.code: assert rtmpSupport  -> rtmpdump != null;
  
  let
    rel = "Krypton";
    ffmpeg_3_1_6 = fetchurl {
      url = "https://github.com/xbmc/FFmpeg/archive/3.1.6-${rel}.tar.gz";
      sha256 = "14jicb26s20nr3qmfpazszpc892yjwjn81zbsb8szy3a5xs19y81";
    };
  in stdenv.mkDerivation rec {
      name = "kodi-" + version;
      version = "17.0";
  
      src = fetchurl {
        url = "https://github.com/xbmc/xbmc/archive/${version}-${rel}.tar.gz";
        sha256 = "0ib59x733yf8ivsw82qlsq43jn5214n668nrn5df2flpjcjgmzsb";
      };
  
      buildInputs = [
  