From e0bd12836bb36d211798b9221e0d7ef976fa447f Mon Sep 17 00:00:00 2001 From: Armeen Mahdian Date: Tue, 22 Mar 2022 23:53:51 -0500 Subject: [PATCH] udis86: 1.7.2 -> unstable-2014-12-25, patch for python3 builds (#165177) Co-authored-by: Sandro --- pkgs/development/tools/udis86/default.nix | 24 ++++++++++++++++++----- 1 file changed, 19 insertions(+), 5 deletions(-) diff --git a/pkgs/development/tools/udis86/default.nix b/pkgs/development/tools/udis86/default.nix index dd4ad058c8da..aec41c7c97a6 100644 --- a/pkgs/development/tools/udis86/default.nix +++ b/pkgs/development/tools/udis86/default.nix @@ -1,17 +1,31 @@ -{ lib, stdenv, fetchFromGitHub, autoreconfHook, python2 }: +{ lib +, stdenv +, fetchFromGitHub +, fetchpatch +, autoreconfHook +, python3 +}: stdenv.mkDerivation rec { pname = "udis86"; - version = "1.7.2"; + version = "unstable-2014-12-25"; src = fetchFromGitHub { owner = "vmt"; repo = "udis86"; - rev = "v${version}"; - sha256 = "0c60zwimim6jrm4saw36s38w5sg5v8n9mr58pkqmjrlf7q9g6am1"; + rev = "56ff6c87c11de0ffa725b14339004820556e343d"; + hash = "sha256-bmm1rgzZeStQJXEmcT8vnplsnmgN3LJlYs7COmqsDU8="; }; - nativeBuildInputs = [ autoreconfHook python2 ]; + patches = [ + (fetchpatch { + name = "support-python3-for-building"; + url = "https://github.com/vmt/udis86/commit/3c05ce60372cb2eba39d6eb87ac05af8a664e1b1.patch"; + hash = "sha256-uF4Cwt7UMkyd0RX6cCMQt9xvkkUNQvTDH/Z/6nHtVT8="; + }) + ]; + + nativeBuildInputs = [ autoreconfHook python3 ]; configureFlags = [ "--enable-shared"