<commit_before>{ stdenv, fetchurl, kernel, perl, makeWrapper, autoconf, automake, libtool }:

assert stdenv.isLinux;

let
  version = "0.8.2";
  #website = https://ftg.lbl.gov/CheckpointRestart;
in

stdenv.mkDerivation {
  name = "blcr-${version}-${kernel.version}";

  src = fetchurl {
    url = https://ftg.lbl.gov/assets/projects/CheckpointRestart/downloads/blcr-0.8.2.tar.gz;
    #url = "${website}/downloads/blcr-${version}.tar.gz";
    sha256 = "1ldvzrajljkm318z5ix1p27n0gmv7gqxij6ck7p5fz4ncdbb01x8";
  };
  
  patchFlags = "-p0";

  patches = map fetchurl [
    { url = http://upc-bugs.lbl.gov/blcr-dist/blcr-0.8.2+kernel-2.6.31.patch01;
      sha256 = "0jnz18kbrm64hahvhk35zakcpylad1khsp5kjxkj19j0lkjv3m4h";
    }
    { url = http://upc-bugs.lbl.gov/blcr-dist/blcr-0.8.2+kernel-2.6.32.patch02;
      sha256 = "1f5s9c7iiaxd67ki3bmz09mf66shzbl97hvwaq4nmk6miq94k1fw";
    }
    { url = http://upc-bugs.lbl.gov/blcr-dist/blcr-0.8.2+kernel-2.6.34.patch03;
      sha256 = "0g2v67n40ikx5hja7zgnc2axif16r2sibi5vf0r4wjzc5z9gdfrh";
    }
  ];

  buildInputs = [ perl makeWrapper autoconf automake libtool ];

  preConfigure = ''
    ./autogen.sh
    configureFlagsArray=(
      --with-linux=$(ls -d ${kernel}/lib/modules/*/build)
      --with-kmod-dir=$out/lib/modules/$(cd ${kernel}/lib/modules; ls -d 2.6.*)
      --with-system-map=${kernel}/System.map
    )
  '';

  postInstall = ''
    for prog in "$out/bin/"*
    do
      wrapProgram "$prog" --prefix LD_LIBRARY_PATH ":" "$out/lib"
    done
  '';
      
  meta = {
    description = "Berkeley Lab Checkpoint/Restart for Linux (BLCR)";
    homepage = https://ftg.lbl.gov/projects/CheckpointRestart/;
    license = "GPL2";
  };
}
<commit_msg>Update BLCR to version 0.8.3<commit_after>{ stdenv, fetchurl, kernel, perl, makeWrapper, autoconf, automake, libtool }:

assert stdenv.isLinux;

stdenv.mkDerivation {
  name = "blcr-0.8.3-${kernel.version}";

  src = fetchurl {
    url = https://ftg.lbl.gov/assets/projects/CheckpointRestart/downloads/blcr-0.8.3.tar.gz;
    sha256 = "c8243c9a7a215d4fc4e8f2199045711cf711a6f2e0b39a94413478ffae110eac";
  };

  buildInputs = [ perl makeWrapper autoconf automake libtool ];

  preConfigure = ''
    ./autogen.sh
    configureFlagsArray=(
      --with-linux=$(ls -d ${kernel}/lib/modules/*/build)
      --with-kmod-dir=$out/lib/modules/$(cd ${kernel}/lib/modules; ls -d 2.6.*)
      --with-system-map=${kernel}/System.map
    )
  '';

  postInstall = ''
    for prog in "$out/bin/"*
    do
      wrapProgram "$prog" --prefix LD_LIBRARY_PATH ":" "$out/lib"
    done
  '';
      
  meta = {
    description = "Berkeley Lab Checkpoint/Restart for Linux (BLCR)";
    homepage = https://ftg.lbl.gov/projects/CheckpointRestart/;
    license = "GPL2";
  };
}

{'fraction_non_alphanumeric': 0.16545189504373178, 'fraction_numerical': 0.06231778425655977, 'mean_word_length': 3.0848214285714284, 'pattern_counts': {'":': 2, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 5, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 3, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2479023', 'n_tokens_mistral': 1214, 'n_tokens_neox': 1139, 'n_words': 153}