Merge pull request #329823 from ExpidusOS/fix/pkgsllvm/elfutils
[NixPkgs.git] / pkgs / by-name / qo / qodem / package.nix
blob3398e9749d0888b4ddc0ba25f8f6e2bd0fd75215
2   lib,
3   stdenv,
4   fetchFromGitLab,
5   fetchpatch2,
6   autoreconfHook,
7   ncurses,
8   SDL,
9   gpm,
10   miniupnpc,
13 stdenv.mkDerivation (finalAttrs: {
14   pname = "qodem";
15   version = "1.0.1-unstable-2022-02-12";
17   src = fetchFromGitLab {
18     owner = "AutumnMeowMeow";
19     repo = "qodem";
20     rev = "69cc7458ef23243f790348a4cc503a8173008e55";
21     hash = "sha256-Ocb2inuxeDOfqge+h7pHL9I9Kn72Mgi8Eq179/58alk=";
22   };
24   patches = [
25     # Fix ICH with count>1
26     # https://gitlab.com/AutumnMeowMeow/qodem/-/issues/77
27     (fetchpatch2 {
28       url = "https://gitlab.com/-/project/6684464/uploads/c2ceaef82d483c13ff9ec64424f3c40a/0001-Fix-ICH-with-count-1.patch";
29       hash = "sha256-lCqj4p8onUS4pehQMXS6lbC7JH5dP6sOjDALpasgd2M=";
30     })
32     # Don't clear line rendition on partial ED
33     # https://gitlab.com/AutumnMeowMeow/qodem/-/issues/78
34     (fetchpatch2 {
35       url = "https://gitlab.com/-/project/6684464/uploads/462c0b1cf05c3fc2857ce982e62fefcc/0001-Don-t-clear-line-rendition-on-partial-ED.patch";
36       hash = "sha256-lSuxP0tUfGa3BjK3ehpdMi16XaGZrdVvAcM2vnjAme8=";
37     })
39     # DECCOLM should clear line rendition attributes
40     # https://gitlab.com/AutumnMeowMeow/qodem/-/issues/78
41     (fetchpatch2 {
42       url = "https://gitlab.com/-/project/6684464/uploads/812bdfdfaee44eed346fcff85f53efbe/0002-DECCOLM-should-clear-line-rendition-attributes.patch";
43       hash = "sha256-XO+h5fpBTLLYC3t4FRCy1uFiMkmSXbre4T2NB/FC3uQ=";
44     })
46     # Fix build with miniupnpc 2.2.8
47     ./qodem-fix-miniupnpc-2.2.8.patch
48   ];
50   nativeBuildInputs = [
51     autoreconfHook
52   ];
54   buildInputs = [
55     ncurses
56     SDL
57     miniupnpc
58   ] ++ lib.optionals (lib.meta.availableOn stdenv.hostPlatform gpm) [
59     gpm
60   ];
62   configureFlags = lib.optionals (!(lib.meta.availableOn stdenv.hostPlatform gpm)) [
63     "--disable-gpm"
64   ];
66   strictDeps = true;
68   enableParallelBuilding = true;
70   __structuredAttrs = true;
72   meta = {
73     homepage = "https://qodem.sourceforge.net/";
74     description = "Re-implementation of the DOS-era Qmodem serial communications package";
75     longDescription = ''
76       Qodem is a from-scratch clone implementation of the Qmodem
77       communications program made popular in the days when Bulletin Board
78       Systems ruled the night. Qodem emulates the dialing directory and the
79       terminal screen features of Qmodem over both modem and Internet
80       connections.
81     '';
82     changelog = "${finalAttrs.src.meta.homepage}-/blob/${finalAttrs.src.rev}/ChangeLog";
83     maintainers = with lib.maintainers; [ embr ];
84     sourceProvenance = [ lib.sourceTypes.fromSource ];
85     license = lib.licenses.publicDomain;
86     platforms = lib.platforms.unix;
87   };