about summary refs log tree commit diff
path: root/pkgs/applications/networking/feedreaders/newsflash/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/applications/networking/feedreaders/newsflash/default.nix')
-rw-r--r--pkgs/applications/networking/feedreaders/newsflash/default.nix115
1 files changed, 65 insertions, 50 deletions
diff --git a/pkgs/applications/networking/feedreaders/newsflash/default.nix b/pkgs/applications/networking/feedreaders/newsflash/default.nix
index e6bc4c841c172..f8fcea67a4896 100644
--- a/pkgs/applications/networking/feedreaders/newsflash/default.nix
+++ b/pkgs/applications/networking/feedreaders/newsflash/default.nix
@@ -1,45 +1,48 @@
-{ lib
-, stdenv
-, rustPlatform
-, fetchFromGitLab
-, cargo
-, meson
-, ninja
-, pkg-config
-, rustc
-, blueprint-compiler
-, wrapGAppsHook4
-, gdk-pixbuf
-, glib
-, gtk4
-, libadwaita
-, libxml2
-, openssl
-, sqlite
-, webkitgtk
-, glib-networking
-, librsvg
-, gst_all_1
-, gitUpdater
+{
+  lib,
+  stdenv,
+  rustPlatform,
+  fetchFromGitLab,
+  substituteAll,
+  cargo,
+  meson,
+  ninja,
+  pkg-config,
+  rustc,
+  blueprint-compiler,
+  wrapGAppsHook4,
+  gdk-pixbuf,
+  glib,
+  clapper,
+  gtk4,
+  libadwaita,
+  libxml2,
+  openssl,
+  sqlite,
+  webkitgtk,
+  glib-networking,
+  librsvg,
+  gst_all_1,
+  gitUpdater,
 }:
 
 stdenv.mkDerivation (finalAttrs: {
   pname = "newsflash";
-  version = "3.1.6";
+  version = "3.3.0";
 
   src = fetchFromGitLab {
     owner = "news-flash";
     repo = "news_flash_gtk";
     rev = "refs/tags/v.${finalAttrs.version}";
-    hash = "sha256-zEf61aKtiuTCmhzkfVkTLtIRCb4DVXVtI+9Az9dU9HE=";
+    hash = "sha256-s8h/OIJJzMmsCsaQJ0SOjCAVXfYQbjOupdDtLOqM9d0=";
   };
 
   cargoDeps = rustPlatform.importCargoLock {
     lockFile = ./Cargo.lock;
     outputHashes = {
-      "news-flash-2.3.0-alpha.0" = "sha256-Gr7EyAbIFABZx9GR/WvshF0vfJaul7wz4pro2EbwSM8=";
-      "newsblur_api-0.2.0" = "sha256-eysCB19znQF8mRwQ64nSp6KuvJ1Trot4g4WCdQDedo8=";
-      "article_scraper-2.0.0" = "sha256-URiteEJ1kXoGfRopGoRI/4iPbzd+F9bQaMJKpkrh/sE=";
+      "clapper-0.1.0" = "sha256-xQ7l6luO5E4PMjtN9elg0bkJa7IhWzA7KuYDJ+m/VY0=";
+      "news-flash-2.3.0-alpha.0" = "sha256-ZgX6tQmPDMSpLcYD04u2ReQXdzeGzQTwGaUy/y4z4do=";
+      "newsblur_api-0.3.0" = "sha256-m2178zdJzeskl3BQpZr6tlxTAADehxz8uYcZzi15nhQ=";
     };
   };
 
@@ -50,12 +53,20 @@ stdenv.mkDerivation (finalAttrs: {
     # be included in $out. They will generated by xdg.mime.enable &
     # gtk.iconCache.enable instead.
     ./no-post-install.patch
+
+    # Replace placeholder "0.0.0" project version with nixpkgs version
+    (substituteAll {
+      src = ./hardcode-version.patch;
+      inherit (finalAttrs) version;
+    })
   ];
 
   postPatch = ''
     patchShebangs build-aux/cargo.sh
   '';
 
+  strictDeps = true;
+
   nativeBuildInputs = [
     meson
     ninja
@@ -73,36 +84,40 @@ stdenv.mkDerivation (finalAttrs: {
     blueprint-compiler
   ];
 
-  buildInputs = [
-    gtk4
-    libadwaita
-    libxml2
-    openssl
-    sqlite
-    webkitgtk
+  buildInputs =
+    [
+      clapper
+      gtk4
+      libadwaita
+      libxml2
+      openssl
+      sqlite
+      webkitgtk
 
-    # TLS support for loading external content in webkitgtk WebView
-    glib-networking
+      # TLS support for loading external content in webkitgtk WebView
+      glib-networking
 
-    # SVG support for gdk-pixbuf
-    librsvg
-  ] ++ (with gst_all_1; [
-    # Audio & video support for webkitgtk WebView
-    gstreamer
-    gst-plugins-base
-    gst-plugins-good
-    gst-plugins-bad
-  ]);
+      # SVG support for gdk-pixbuf
+      librsvg
+    ]
+    ++ (with gst_all_1; [
+      # Audio & video support for webkitgtk WebView
+      gstreamer
+      gst-plugins-base
+      gst-plugins-good
+      gst-plugins-bad
+    ]);
 
-  passthru.updateScript = gitUpdater {
-    rev-prefix = "v.";
-  };
+  passthru.updateScript = gitUpdater { rev-prefix = "v."; };
 
   meta = with lib; {
     description = "A modern feed reader designed for the GNOME desktop";
     homepage = "https://gitlab.com/news-flash/news_flash_gtk";
     license = licenses.gpl3Plus;
-    maintainers = with maintainers; [ kira-bruneau stunkymonkey ];
+    maintainers = with maintainers; [
+      kira-bruneau
+      stunkymonkey
+    ];
     platforms = platforms.unix;
     mainProgram = "io.gitlab.news_flash.NewsFlash";
   };