<commit_before>{ stdenv, fetchFromGitHub, cmake, pkgconfig
, boost, bison, curl, ncurses, openssl, xxd
, libaio, libev, libgcrypt, libgpgerror, libtool, zlib
}:

stdenv.mkDerivation rec {
  pname = "percona-xtrabackup";
  version = "2.4.12";

  src = fetchFromGitHub {
    owner = "percona";
    repo = "percona-xtrabackup";
    rev = "${pname}-${version}";
    sha256 = "1w17v2c677b3vfnm81bs63kjbfiin7f12wl9fbgp83hfpyx5msan";
  };

  nativeBuildInputs = [ cmake pkgconfig ];

  buildInputs = [
    boost bison curl ncurses openssl xxd
    libaio libev libgcrypt libgpgerror libtool zlib
  ];

  cmakeFlags = [
    "-DBUILD_CONFIG=xtrabackup_release"
    "-DINSTALL_MYSQLTESTDIR=OFF"
    "-DWITH_BOOST=system"
    "-DWITH_SSL=system"
    "-DWITH_ZLIB=system"
    "-DWITH_MAN_PAGES=OFF"
    "-DCMAKE_CXX_FLAGS=-std=gnu++03"
  ];

  postInstall = ''
    rm -r "$out"/lib/plugin/debug
  '';

  meta = with stdenv.lib; {
    description = "Non-blocking backup tool for MySQL";
    homepage = "http://www.percona.com/software/percona-xtrabackup";
    license = licenses.lgpl2;
    platforms = platforms.linux;
    maintainers = with maintainers; [ izorkin ];
  };
}<commit_msg>percona-xtrabackup 2.4: 2.4.12 -> 2.4.20<commit_after>{ stdenv, fetchFromGitHub, bison, boost, cmake, makeWrapper, pkgconfig
, curl, cyrus_sasl, libaio, libedit, libev, libevent, libgcrypt, libgpgerror, lz4
, ncurses, numactl, openssl, protobuf, valgrind, xxd, zlib
, perlPackages
}:

stdenv.mkDerivation rec {
  pname = "percona-xtrabackup";
  version = "2.4.20";

  src = fetchFromGitHub {
    owner = "percona";
    repo = "percona-xtrabackup";
    rev = "${pname}-${version}";
    sha256 = "0awdpkcgvx2aq7pwxy8jyzkin6cyrrh3d576x9ldm851kis9n5ii";
  };

  nativeBuildInputs = [ bison boost cmake makeWrapper pkgconfig ];

  buildInputs = [
    curl cyrus_sasl libaio libedit libev libevent libgcrypt libgpgerror lz4
    ncurses numactl openssl protobuf valgrind xxd zlib
  ] ++ (with perlPackages; [ perl DBI DBDmysql ]);

  cmakeFlags = [
    "-DMYSQL_UNIX_ADDR=/run/mysqld/mysqld.sock"
    "-DBUILD_CONFIG=xtrabackup_release"
    "-DINSTALL_MYSQLTESTDIR=OFF"
    "-DWITH_BOOST=system"
    "-DWITH_CURL=system"
    "-DWITH_EDITLINE=system"
    "-DWITH_LIBEVENT=system"
    "-DWITH_LZ4=system"
    "-DWITH_PROTOBUF=system"
    "-DWITH_SASL=system"
    "-DWITH_SSL=system"
    "-DWITH_ZLIB=system"
    "-DWITH_VALGRIND=ON"
    "-DWITH_MAN_PAGES=OFF"
    "-DCMAKE_SKIP_BUILD_RPATH=OFF" # To run libmysql/libmysql_api_test during build.
  ];

  postInstall = ''
    wrapProgram "$out"/bin/xtrabackup --prefix PERL5LIB : $PERL5LIB
    rm -r "$out"/lib/plugin/debug
  '';

  meta = with stdenv.lib; {
    description = "Non-blocking backup tool for MySQL";
    homepage = "http://www.percona.com/software/percona-xtrabackup";
    license = licenses.lgpl2;
    platforms = platforms.linux;
    maintainers = with maintainers; [ izorkin ];
  };
}
{'fraction_non_alphanumeric': 0.12907655338139376, 'fraction_numerical': 0.023000343288705802, 'mean_word_length': 3.738211382113821, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2133816', 'n_tokens_mistral': 1219, 'n_tokens_neox': 1148, 'n_words': 201}