biglybt: 3.5.0.0 -> 3.6.0.0
[NixPkgs.git] / pkgs / applications / editors / hexcurse / default.nix
blob17291a458a4b532f7a3a373f20c2e5bfde2f2cc6
1 { stdenv, lib, fetchFromGitHub, fetchpatch, ncurses }:
3 stdenv.mkDerivation rec {
4   pname = "hexcurse";
5   version = "1.60.0";
7   src = fetchFromGitHub {
8     owner = "LonnyGomes";
9     repo = "hexcurse";
10     rev = "v${version}";
11     sha256 = "17ckkxfzbqvvfdnh10if4aqdcq98q3vl6dn1v6f4lhr4ifnyjdlk";
12   };
13   buildInputs = [ ncurses ];
14   env.NIX_CFLAGS_COMPILE = toString [ "-Wno-error=stringop-overflow" "-Wno-error=stringop-truncation" ];
15   patches = [
16     # gcc7 compat
17     (fetchpatch {
18       url = "https://github.com/LonnyGomes/hexcurse/commit/d808cb7067d1df067f8b707fabbfaf9f8931484c.patch";
19       sha256 = "0h8345blmc401c6bivf0imn4cwii67264yrzxg821r46wrnfvyi2";
20     })
21     # gcc7 compat
22     (fetchpatch {
23       url = "https://github.com/LonnyGomes/hexcurse/commit/716b5d58ac859cc240b8ccb9cbd79ace3e0593c1.patch";
24       sha256 = "0v6gbp6pjpmnzswlf6d97aywiy015g3kcmfrrkspsbb7lh1y3nix";
25     })
27     # Fix pending upstream inclusion for gcc10 -fno-common compatibility:
28     #  https://github.com/LonnyGomes/hexcurse/pull/28
29     (fetchpatch {
30       name = "fno-common.patch";
31       url = "https://github.com/LonnyGomes/hexcurse/commit/9cf7c9dcd012656df949d06f2986b57db3a72bdc.patch";
32       sha256 = "1awsyxys4pd3gkkgyckgjg3njgqy07223kcmnpfdkidh2xb0s360";
33     })
35     # Fix pending upstream inclusion for ncurses-6.3 support:
36     #  https://github.com/LonnyGomes/hexcurse/pull/40
37     (fetchpatch {
38       name = "ncurses-6.3.patch";
39       url = "https://github.com/LonnyGomes/hexcurse/commit/cb70d4a93a46102f488f471fad31a7cfc9fec025.patch";
40       sha256 = "19674zhhp7gc097kl4bxvi0gblq6jzjy8cw8961svbq5y3hv1v5y";
41     })
42   ];
44   meta = with lib; {
45     description = "ncurses-based console hexeditor written in C";
46     homepage = "https://github.com/LonnyGomes/hexcurse";
47     license = licenses.gpl2;
48     platforms = platforms.linux;
49     maintainers = with maintainers; [ ];
50     mainProgram = "hexcurse";
51   };