<commit_before>{ nixpkgs ? <nixpkgs>
, systems ? [ "i686-linux" "x86_64-linux" ]
, buildForAmiga ? false
, buildForWindows ? false
, amigaosenvPath ? <amigaosenv>
, libamivideo ? {outPath = ./.; rev = 1234;}
, officialRelease ? false
}:

let
  pkgs = import nixpkgs {};
  
  version = builtins.readFile ./version;
  
  jobs = rec {
    tarball =
      with pkgs;

      releaseTools.sourceTarball {
        name = "libamivideo-tarball";
        src = libamivideo;
        inherit version officialRelease;

        buildInputs = [];
      };
      
    build =
      (pkgs.lib.genAttrs systems (system:
        with import nixpkgs { inherit system; };
        
        releaseTools.nixBuild {
          name = "libamivideo";
          inherit version;
          src = tarball;
          CFLAGS = "-ansi -pedantic -Wall";
        }
      )) //
        (pkgs.lib.optionalAttrs (buildForWindows) { i686-windows =
           pkgs.dotnetenv.buildSolution {
             name = "libamivideo";
             src = ./.;
             baseDir = "src";
             slnFile = "libamivideo.sln";
             postInstall = ''
               mkdir -p $out/include/libamivideo
               cp -v libamivideo/*.h $out/include/libamivideo
             '';
           };
        }) //
      (pkgs.lib.optionalAttrs (buildForAmiga)
        (let
          amigaosenv = import amigaosenvPath {
            inherit (pkgs) stdenv uae procps;
            lndir = pkgs.xorg.lndir;
          };
        in
        {
          m68k-amigaos = amigaosenv.mkDerivation {
            name = "libamivideo-${version}";
            src = "${tarball}/tarballs/libamivideo-${version}pre1234.tar.gz";
      
            buildCommand = ''
              tar xfvz $src
              cd libamivideo-${version}pre1234
              CFLAGS='-noixemul -O3' ./configure --prefix=/OUT --disable-shared
              make
              make check
              make install
            '';
          };<commit_msg>Fix to work with new AmigaOS build function<commit_after>{ nixpkgs ? <nixpkgs>
, systems ? [ "i686-linux" "x86_64-linux" ]
, buildForAmiga ? false
, buildForWindows ? false
, amigaosenvPath ? <amigaosenv>
, kickstartROMFile ? null
, baseDiskImage ? null
, useUAE ? true
, libamivideo ? {outPath = ./.; rev = 1234;}
, officialRelease ? false
}:

let
  pkgs = import nixpkgs {};
  
  version = builtins.readFile ./version;
  
  jobs = rec {
    tarball =
      with pkgs;

      releaseTools.sourceTarball {
        name = "libamivideo-tarball";
        src = libamivideo;
        inherit version officialRelease;

        buildInputs = [];
      };
      
    build =
      (pkgs.lib.genAttrs systems (system:
        with import nixpkgs { inherit system; };
        
        releaseTools.nixBuild {
          name = "libamivideo";
          inherit version;
          src = tarball;
          CFLAGS = "-ansi -pedantic -Wall";
        }
      )) //
        (pkgs.lib.optionalAttrs (buildForWindows) { i686-windows =
           pkgs.dotnetenv.buildSolution {
             name = "libamivideo";
             src = ./.;
             baseDir = "src";
             slnFile = "libamivideo.sln";
             postInstall = ''
               mkdir -p $out/include/libamivideo
               cp -v libamivideo/*.h $out/include/libamivideo
             '';
           };
        }) //
      (pkgs.lib.optionalAttrs (buildForAmiga)
        (let
          amigaosenv = import amigaosenvPath {
            inherit (pkgs) stdenv fetchurl lhasa uae fsuae procps bchunk cdrtools;
            inherit (pkgs.xorg) lndir;
          };
        in
        {
          m68k-amigaos = amigaosenv.mkDerivation {
            name = "libamivideo-${version}";
            src = "${tarball}/tarballs/libamivideo-${version}pre1234.tar.gz";
      
            buildCommand = ''
              tar xfvz $src
              cd libamivideo-${version}pre1234
              CFLAGS='-noixemul -O3' ./configure --prefix=/OUT --disable-shared
              make
              make check
              make install
            '';
            inherit kickstartROMFile baseDiskImage useUAE;
          };
{'fraction_non_alphanumeric': 0.11019617340760475, 'fraction_numerical': 0.012109469605231292, 'mean_word_length': 1.565217391304348, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, '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': '6663070', 'n_tokens_mistral': 1326, 'n_tokens_neox': 1268, 'n_words': 251}