Unverified Commit 0440181d authored by Anthony's avatar Anthony Committed by GitHub
Browse files

winetricks: 20250102 -> 20260125 (#484159)

parents 0eca1f01 cfcd72b9
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -254,8 +254,8 @@ rec {

  winetricks = fetchFromGitHub rec {
    # https://github.com/Winetricks/winetricks/releases
    version = "20250102";
    hash = "sha256-Km2vVTYsLs091cjmNTW8Kqku3vdsEA0imTtZfqZWDQo=";
    version = "20260125";
    hash = "sha256-uIBVESebsH7rXnxWd/qlrZxcG7Y486PctHzcLz29HDk=";
    owner = "Winetricks";
    repo = "winetricks";
    rev = version;
+47 −31
Original line number Diff line number Diff line
@@ -2,20 +2,23 @@
  lib,
  stdenv,
  callPackage,
  perl,
  which,
  makeWrapper,
  bash,
  cabextract,
  coreutils,
  zenity,
  curl,
  cabextract,
  unzip,
  p7zip,
  gnused,
  gnugrep,
  bash,
  gawk,
  gnugrep,
  gnused,
  gnutar,
  gzip,
  p7zip,
  perl,
  unzip,
  which,
  zenity,
  unrar-free,
  versionCheckHook,
}:

stdenv.mkDerivation rec {
@@ -27,34 +30,47 @@ stdenv.mkDerivation rec {
  buildInputs = [
    perl
    which
    makeWrapper
  ];

  # coreutils is for sha1sum
  pathAdd = lib.makeBinPath [
    perl
    which
  makeFlags = [ "PREFIX=$(out)" ];

  doCheck = false; # requires "bashate"

  doInstallCheck = true;
  nativeInstallCheckInputs = [ versionCheckHook ];

  postPatch = ''
    patchShebangs src/winetricks
    substituteInPlace src/winetricks \
      --replace-fail 'command -v unrar' 'command -v unrar-free' \
      --replace-fail 'w_try unrar' 'w_try unrar-free'
  '';

  postInstall =
    let
      runtimeDependencies = [
        bash
        cabextract
        coreutils
    zenity
        curl
    cabextract
    unzip
    p7zip
    gnused
    gnugrep
    bash
        gawk
        gnugrep
        gnused
        gnutar
        gzip
        p7zip
        perl
        unrar-free
        unzip
        which
        zenity
      ];

  makeFlags = [ "PREFIX=$(out)" ];

  doCheck = false; # requires "bashate"

  postInstall = ''
    sed -i \
      -e '2i PATH="${pathAdd}:$PATH"' \
      "$out/bin/winetricks"
    in
    ''
      wrapProgram $out/bin/winetricks \
        --prefix PATH : "${lib.makeBinPath runtimeDependencies}" \
        --set WINETRICKS_LATEST_VERSION_CHECK "disabled"
    '';

  passthru = {