<commit_before>x@{builderDefsPackage
  , unzip, cmake, mesa, freeglut, libX11, xproto
  , inputproto, libXi
  , ...}:
builderDefsPackage
(a :  
let 
  helperArgNames = ["stdenv" "fetchurl" "builderDefsPackage"] ++ 
    [];

  buildInputs = map (n: builtins.getAttr n x)
    (builtins.attrNames (builtins.removeAttrs x helperArgNames));
  sourceInfo = rec {
    baseName="box2d";
    version="2.1.2";
    name="${baseName}-${version}";
    url="http://box2d.googlecode.com/files/Box2D_v${version}.zip";
    hash="0m5szd74ig8yqazwk2g3zl4z7wwp08k52awawk1pigy6a4z1qd9v";
  };
in
rec {
  src = a.fetchurl {
    url = sourceInfo.url;
    sha256 = sourceInfo.hash;
  };

  inherit (sourceInfo) name version;
  inherit buildInputs;

  phaseNames = ["changeSettings" "doCmake" "doMakeInstall"];

  changeSettings = a.fullDepEntry ''
    sed -i Box2D/Common/b2Settings.h -e 's@b2_maxPolygonVertices .*@b2_maxPolygonVertices 15@'
  '' ["minInit" "addInputs" "doUnpack"];
      
  goSrcDir = ''cd Box2D'';

  doCmake = a.fullDepEntry ''
    cd Build; 
    cmake -DBOX2D_INSTALL=ON -DBOX2D_BUILD_SHARED=ON -DCMAKE_INSTALL_PREFIX=$out ..
  '' ["minInit" "addInputs" "doUnpack"];
      
  meta = {
    description = "2D physics engine";
    maintainers = with a.lib.maintainers;
    [
      raskin
    ];
    platforms = with a.lib.platforms;
      linux;
    license = "bsd";
  };
  passthru = {
    updateInfo = {
      downloadPage = "http://code.google.com/p/box2d/downloads/list";
    };
  };
}) x

<commit_msg>Update Box2D to 2.3.0. I fail to build 2.3.1, though.<commit_after>x@{builderDefsPackage
  , unzip, cmake, mesa, freeglut, libX11, xproto
  , inputproto, libXi, fetchsvn, pkgconfig
  , ...}:
builderDefsPackage
(a :  
let 
  helperArgNames = ["stdenv" "fetchurl" "builderDefsPackage"] ++ 
    [];

  buildInputs = map (n: builtins.getAttr n x)
    (builtins.attrNames (builtins.removeAttrs x helperArgNames));
in
rec {
  version = "2.3.0";
  name = "box2d-${version}";
  srcDrv = a.fetchsvn {
    url = "http://box2d.googlecode.com/svn/trunk";
    rev = "277";
    sha256 = "1xp93yw2zcqhmh999v7cwqaqxq1glgyg5r8kfm4yabc1ypba3in4";
  };
  src = srcDrv + "/";

  inherit buildInputs;

  phaseNames = ["changeSettings" "doCmake" "doMakeInstall"];

  changeSettings = a.fullDepEntry ''
    sed -i Box2D/Common/b2Settings.h -e 's@b2_maxPolygonVertices .*@b2_maxPolygonVertices 15@'
  '' ["minInit" "addInputs" "doUnpack"];
      
  goSrcDir = ''cd Box2D'';

  doCmake = a.fullDepEntry ''
    cd Build; 
    cmake -DBOX2D_INSTALL=ON -DBOX2D_BUILD_SHARED=ON -DCMAKE_INSTALL_PREFIX=$out ..
  '' ["minInit" "addInputs" "doUnpack"];
      
  meta = {
    description = "2D physics engine";
    maintainers = with a.lib.maintainers;
    [
      raskin
    ];
    platforms = with a.lib.platforms;
      linux;
    license = "bsd";
    inherit version;
  };
}) x


{'fraction_non_alphanumeric': 0.146965976850228, 'fraction_numerical': 0.02981410031567871, 'mean_word_length': 3.2630792227204783, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, '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': '1359783', 'n_tokens_mistral': 1170, 'n_tokens_neox': 1120, 'n_words': 200}