<commit_before>{ stdenv, fetchurl, fetchpatch, gettext, perlPackages, buildPackages }:

stdenv.mkDerivation rec {
  pname = "intltool";
  version = "0.51.0";

  src = fetchurl {
    url = "https://launchpad.net/intltool/trunk/${version}/+download/${pname}-${version}.tar.gz";
    sha256 = "1karx4sb7bnm2j67q0q74hspkfn6lqprpy5r99vkn5bb36a4viv7";
  };

  # fix "unescaped left brace" errors when using intltool in some cases
  patches = [(fetchpatch {
    name = "perl5.26-regex-fixes.patch";
    url = [
      "https://sources.debian.org/data/main/i/intltool/0.51.0-5/debian/patches/perl5.26-regex-fixes.patch"
      "https://src.fedoraproject.org/rpms/intltool/raw/d8d2ef29fb122a42a6b6678eb1ec97ae56902af2/f/intltool-perl5.26-regex-fixes.patch"
    ];
    sha256 = "12q2140867r5d0dysly72khi7b0mm2gd7nlm1k81iyg7fxgnyz45";
  })];

  nativeBuildInputs = with perlPackages; [ perl XMLParser ];
  propagatedBuildInputs = [ gettext ];

  postInstall = stdenv.lib.optionalString (stdenv.hostPlatform != stdenv.buildPlatform) ''
    for f in $out/bin/*; do
      substituteInPlace $f --replace "${buildPackages.perl}" "${perlPackages.perl}"
    done
  '';<commit_msg>intltool: add perl to propagatedBuildInputs<commit_after>{ stdenv, fetchurl, fetchpatch, gettext, perlPackages, buildPackages }:

stdenv.mkDerivation rec {
  pname = "intltool";
  version = "0.51.0";

  src = fetchurl {
    url = "https://launchpad.net/intltool/trunk/${version}/+download/${pname}-${version}.tar.gz";
    sha256 = "1karx4sb7bnm2j67q0q74hspkfn6lqprpy5r99vkn5bb36a4viv7";
  };

  # fix "unescaped left brace" errors when using intltool in some cases
  patches = [(fetchpatch {
    name = "perl5.26-regex-fixes.patch";
    url = [
      "https://sources.debian.org/data/main/i/intltool/0.51.0-5/debian/patches/perl5.26-regex-fixes.patch"
      "https://src.fedoraproject.org/rpms/intltool/raw/d8d2ef29fb122a42a6b6678eb1ec97ae56902af2/f/intltool-perl5.26-regex-fixes.patch"
    ];
    sha256 = "12q2140867r5d0dysly72khi7b0mm2gd7nlm1k81iyg7fxgnyz45";
  })];

  nativeBuildInputs = with perlPackages; [ perl XMLParser ];
  propagatedBuildInputs = [ gettext ] ++ (with perlPackages; [ perl XMLParser ]);

  postInstall = stdenv.lib.optionalString (stdenv.hostPlatform != stdenv.buildPlatform) ''
    for f in $out/bin/*; do
      substituteInPlace $f --replace "${buildPackages.perl}" "${perlPackages.perl}"
    done
  '';
{'fraction_non_alphanumeric': 0.14303638644918445, 'fraction_numerical': 0.07360936846507737, 'mean_word_length': 4.133047210300429, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 6, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3863704', 'n_tokens_mistral': 1041, 'n_tokens_neox': 958, 'n_words': 130}