From 39035bd2630b15e2f18ed3eb7d399d85d53db5af Mon Sep 17 00:00:00 2001
From: Weijia Wang <9713184+wegank@users.noreply.github.com>
Date: Tue, 26 Mar 2024 03:34:01 +0100
Subject: [PATCH 1/3] gnunet: 0.20.0 -> 0.21.1

---
 pkgs/applications/networking/p2p/gnunet/default.nix | 10 +++-------
 1 file changed, 3 insertions(+), 7 deletions(-)

diff --git a/pkgs/applications/networking/p2p/gnunet/default.nix b/pkgs/applications/networking/p2p/gnunet/default.nix
index 27476d3b48a7..3f5e2f7c58a2 100644
--- a/pkgs/applications/networking/p2p/gnunet/default.nix
+++ b/pkgs/applications/networking/p2p/gnunet/default.nix
@@ -7,11 +7,11 @@
 
 stdenv.mkDerivation rec {
   pname = "gnunet";
-  version = "0.20.0";
+  version = "0.21.1";
 
   src = fetchurl {
-    url = "mirror://gnu/gnunet/${pname}-${version}.tar.gz";
-    sha256 = "sha256-VgKeeKmcBNUrE1gJSuUHTkzY6puYz2hV9XrZryeslRg=";
+    url = "mirror://gnu/gnunet/gnunet-${version}.tar.gz";
+    hash = "sha256-k+aLPqynCHJz49doX+auOLLoBV5MnnANNg3UBVJJeFw=";
   };
 
   enableParallelBuilding = true;
@@ -34,10 +34,6 @@ stdenv.mkDerivation rec {
     # builds.
     find . \( -iname \*test\*.c -or -name \*.conf \) | \
       xargs sed -ie "s|/tmp|$TMPDIR|g"
-
-    sed -ie 's|@LDFLAGS@|@LDFLAGS@ $(Z_LIBS)|g' \
-      src/regex/Makefile.in \
-      src/fs/Makefile.in
   '';
 
   # unfortunately, there's still a few failures with impure tests

From 8922d75e9314b1b9586e4241bf4cead018046dae Mon Sep 17 00:00:00 2001
From: Weijia Wang <9713184+wegank@users.noreply.github.com>
Date: Tue, 26 Mar 2024 03:34:14 +0100
Subject: [PATCH 2/3] gnunet-gtk: 0.20.0 -> 0.21.0

---
 pkgs/applications/networking/p2p/gnunet/gtk.nix | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/pkgs/applications/networking/p2p/gnunet/gtk.nix b/pkgs/applications/networking/p2p/gnunet/gtk.nix
index 94504f2b9956..640ffeef7588 100644
--- a/pkgs/applications/networking/p2p/gnunet/gtk.nix
+++ b/pkgs/applications/networking/p2p/gnunet/gtk.nix
@@ -13,11 +13,11 @@
 
 stdenv.mkDerivation rec {
   pname = "gnunet-gtk";
-  version = "0.20.0";
+  version = "0.21.0";
 
   src = fetchurl {
-    url = "mirror://gnu/gnunet/${pname}-${version}.tar.gz";
-    sha256 = "sha256-6ZHlDIKrTmr/aRz4k5FtRVxZ7B9Hlh2w42QT4YRsVi0=";
+    url = "mirror://gnu/gnunet/gnunet-gtk-${version}.tar.gz";
+    hash = "sha256-vQFtKFI57YG64WpKVngx1kq687hI+f1kpP9ooK53/aw=";
   };
 
   nativeBuildInputs= [

From d8102af47387d2923b145ef2222a571f5be1ed6f Mon Sep 17 00:00:00 2001
From: Weijia Wang <9713184+wegank@users.noreply.github.com>
Date: Wed, 10 Apr 2024 10:55:10 +0200
Subject: [PATCH 3/3] taler: 0.9.3 -> 0.10.1

---
 .../applications/networking/taler/default.nix | 24 ++++++++++++-------
 1 file changed, 15 insertions(+), 9 deletions(-)

diff --git a/pkgs/applications/networking/taler/default.nix b/pkgs/applications/networking/taler/default.nix
index c1de12fb9427..babdff54f185 100644
--- a/pkgs/applications/networking/taler/default.nix
+++ b/pkgs/applications/networking/taler/default.nix
@@ -1,15 +1,15 @@
 { lib, stdenv, fetchgit, curl, gnunet, jansson, libgcrypt, libmicrohttpd
 , qrencode, libsodium, libtool, libunistring, pkg-config, postgresql
-, autoreconfHook, python39, recutils, wget, jq, gettext, texinfo
+, autoreconfHook, python3, recutils, wget, jq, gettext, texinfo
 }:
 
 let
-  version = "0.9.3";
+  version = "0.10.1";
 
   taler-wallet-core = fetchgit {
     url = "https://git.taler.net/wallet-core.git";
     rev = "v${version}";
-    sha256 = "sha256-oL8vi8gxPjKxRpioMs0GLvkzlTkrm1kyvhsXOgrtvVQ=";
+    hash = "sha256-sgiJd1snN9JDqS7IUeORKL60Gcm7XwL/JCX3sNRDTdY=";
   };
 
   taler-exchange = stdenv.mkDerivation {
@@ -20,7 +20,7 @@ let
       url = "https://git.taler.net/exchange.git";
       rev = "v${version}";
       fetchSubmodules = true;
-      sha256 = "sha256-NgDZF6LNeJI4ZuXEwoRdFG6g0S9xNTVhszzlfAnzVOs=";
+      hash = "sha256-SKnMep8bMQaJt4r3u0SrzwYSuFbzv4RnflbutSqwtPg=";
 
       # When fetching submodules without the .git folder we get the following error:
       # "Server does not allow request for unadvertised object"
@@ -45,14 +45,20 @@ let
       gettext
       texinfo # Fix 'makeinfo' is missing on your system.
       libunistring
-      python39.pkgs.jinja2
+      python3.pkgs.jinja2
       # jq is necessary for some tests and is checked by configure script
       jq
     ];
     propagatedBuildInputs = [ gnunet ];
 
-    preConfigure = ''
+    # From ./bootstrap
+    preAutoreconf = ''
       ./contrib/gana-generate.sh
+      pushd contrib
+      find wallet-core/aml-backoffice/ -type f -printf '  %p \\\n' | sort > Makefile.am.ext
+      truncate -s -2 Makefile.am.ext
+      cat Makefile.am.in Makefile.am.ext >> Makefile.am
+      popd
     '';
 
     enableParallelBuilding = true;
@@ -87,7 +93,7 @@ let
       url = "https://git.taler.net/merchant.git";
       rev = "v${version}";
       fetchSubmodules = true;
-      sha256 = "sha256-HewCqyO/7nnIQY9Tgva0k1nTk2LuwLyGK/UUxvx9BG0=";
+      hash = "sha256-8VpoyloLpd/HckSIRU6IclWUXQyEHqlcNdoJI9U3t0Y=";
     };
     postUnpack = ''
       ln -s ${taler-wallet-core}/spa.html $sourceRoot/contrib/
@@ -104,11 +110,11 @@ let
 
     # From ./bootstrap
     preAutoreconf = ''
-      cd contrib
+      pushd contrib
       find wallet-core/backoffice/ -type f -printf '  %p \\\n' | sort > Makefile.am.ext
       truncate -s -2 Makefile.am.ext
       cat Makefile.am.in Makefile.am.ext >> Makefile.am
-      cd ..
+      popd
     '';
     configureFlags = [
       "--with-gnunet=${gnunet}"