about summary refs log tree commit diff
path: root/pkgs/by-name/gn/gnome-feeds/package.nix
blob: e502a17bdbed1f4fa0500cdc1fc798c6326f0987 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
{
  lib,
  python3,

  fetchFromGitLab,
  fetchpatch,

  appstream,
  gobject-introspection,
  meson,
  ninja,
  pkg-config,
  blueprint-compiler,
  wrapGAppsHook4,

  glib-networking,
  libadwaita,
  webkitgtk_6_0,
}:

python3.pkgs.buildPythonApplication rec {
  pname = "gnome-feeds";
  version = "2.2.0";
  pyproject = false;

  src = fetchFromGitLab {
    domain = "gitlab.gnome.org";
    owner = "World";
    repo = "gfeeds";
    rev = version;
    hash = "sha256-XKwRFjz4ocH01mj8KshLGmGxbm/uvDiyYRf65KL0UFw=";
  };

  patches = [
    # both patches needed to built with newer blueprint-compiler
    (fetchpatch {
      name = "fix-for-blueprint-0.8.patch";
      url = "https://gitlab.gnome.org/World/gfeeds/-/commit/cfe860f44f685be302e2ad9f30b55bab08e078ce.patch";
      hash = "sha256-exkq9KykB60/X8u3+T1/sShrhGP8BvNkaBWPzm2mchc=";
    })
    (fetchpatch {
      name = "upgrade-blueprint-0.8-syntax.patch";
      url = "https://gitlab.gnome.org/World/gfeeds/-/commit/d099fda0c62e338080061683a154f711cc487b30.patch";
      hash = "sha256-M6QLRTj+CItk3XPDeexf3/+B1YHJoHsTjwdE6iw1xjM=";
    })
  ];

  nativeBuildInputs = [
    appstream
    gobject-introspection
    meson
    ninja
    pkg-config
    blueprint-compiler
    wrapGAppsHook4
  ];

  buildInputs = [
    glib-networking
    libadwaita
    webkitgtk_6_0
  ];

  dependencies = with python3.pkgs; [
    beautifulsoup4
    humanize
    python-dateutil
    syndication-domination
    python-magic
    pillow
    pygments
    pygobject3
    readability-lxml
    pytz
    requests
  ];

  dontWrapGApps = true;

  preFixup = ''
    makeWrapperArgs+=("''${gappsWrapperArgs[@]}")
  '';

  meta = {
    description = "RSS/Atom feed reader for GNOME";
    mainProgram = "gfeeds";
    homepage = "https://gitlab.gnome.org/World/gfeeds";
    license = lib.licenses.gpl3Plus;
    maintainers = with lib.maintainers; [
      pbogdan
      aleksana
    ];
    platforms = lib.platforms.linux;
  };
}