about summary refs log tree commit diff
path: root/pkgs/tools/security/decoder
diff options
context:
space:
mode:
authorSergei Trofimovich <slyich@gmail.com>2022-07-09 08:18:37 +0100
committerSergei Trofimovich <slyich@gmail.com>2022-07-09 08:18:37 +0100
commitb55d83f112ac82a05e8edcc7d5502da73c59e173 (patch)
treea5f0c8f24d31b5c49130d9fe83b51c26949318b5 /pkgs/tools/security/decoder
parent95e157f6705ce856225fa214dc0ec8720a29ff71 (diff)
decoder: pull patch pending upstream inclusion for -fno-common toolchains
Without the change build fails on `staging` as:

    ld: decoder.o:(.bss.usageScreen+0x0): multiple definition of
      `usageScreen'; errors.o:(.bss.usageScreen+0x0): first defined here
Diffstat (limited to 'pkgs/tools/security/decoder')
-rw-r--r--pkgs/tools/security/decoder/default.nix11
1 files changed, 11 insertions, 0 deletions
diff --git a/pkgs/tools/security/decoder/default.nix b/pkgs/tools/security/decoder/default.nix
index baaacac5da8af..76dd3003d5001 100644
--- a/pkgs/tools/security/decoder/default.nix
+++ b/pkgs/tools/security/decoder/default.nix
@@ -1,6 +1,7 @@
 { lib
 , stdenv
 , fetchFromGitHub
+, fetchpatch
 , openssl
 }:
 
@@ -15,6 +16,16 @@ stdenv.mkDerivation rec {
     sha256 = "sha256-1sT1/iwtc2ievmLuNuooy9b14pTs1ZC5noDwzFelk7w=";
   };
 
+  patches = [
+    # Pull fix pending upstream inclusion for -fno-common toolchains:
+    #   https://github.com/PeterPawn/decoder/pull/29
+    (fetchpatch {
+      name = "fno-common.patch";
+      url = "https://github.com/PeterPawn/decoder/commit/843ac477c31108023d8008581bf91c5a3acc1859.patch";
+      sha256 = "sha256-rRylz8cxgNyPSqL/THdgEBpzcVx1K+xbjUn4PwP9Jn4=";
+    })
+  ];
+
   buildInputs = [
     openssl
   ];