diff options
author | Yongun Seong <nevivurn@nevi.dev> | 2023-09-25 15:29:41 +0900 |
---|---|---|
committer | Anderson Torres <torres.anderson.85@protonmail.com> | 2023-10-01 17:29:24 -0300 |
commit | f4599feae4160285c5ce4e4364bd147df83e780c (patch) | |
tree | eed5cd73e6fed7a0aa972b9b2ae9c76ad894487e /pkgs/applications/office/gnucash/default.nix | |
parent | 5dea4f1dbf74d8834578fcc80eba535c9fb4f4c4 (diff) | |
download | nixpkgs-f4599feae4160285c5ce4e4364bd147df83e780c.tar nixpkgs-f4599feae4160285c5ce4e4364bd147df83e780c.tar.gz nixpkgs-f4599feae4160285c5ce4e4364bd147df83e780c.tar.bz2 nixpkgs-f4599feae4160285c5ce4e4364bd147df83e780c.tar.lz nixpkgs-f4599feae4160285c5ce4e4364bd147df83e780c.tar.xz nixpkgs-f4599feae4160285c5ce4e4364bd147df83e780c.tar.zst nixpkgs-f4599feae4160285c5ce4e4364bd147df83e780c.zip |
gnucash: 5.3 -> 5.4
Also: - Remove old, no longer relevant patches - Update 0004-exec-fq-wrapper.patch so it applies cleanly on 5.4 - Patch flaky test - Remove the word "gnome", it breaks r-ryantm - Wrap gnucash-cli the same way as the main binary - Set meta.mainProgram
Diffstat (limited to 'pkgs/applications/office/gnucash/default.nix')
-rw-r--r-- | pkgs/applications/office/gnucash/default.nix | 20 |
1 files changed, 14 insertions, 6 deletions
diff --git a/pkgs/applications/office/gnucash/default.nix b/pkgs/applications/office/gnucash/default.nix index ae843bcf0f1..eacda570cc0 100644 --- a/pkgs/applications/office/gnucash/default.nix +++ b/pkgs/applications/office/gnucash/default.nix @@ -1,6 +1,7 @@ { lib , stdenv , fetchurl +, fetchpatch , aqbanking , boost , cmake @@ -26,12 +27,13 @@ stdenv.mkDerivation rec { pname = "gnucash"; - version = "5.3"; + version = "5.4"; # raw source code doesn't work out of box; fetchFromGitHub not usable src = fetchurl { - url = "https://github.com/Gnucash/gnucash/releases/download/${version}/${pname}-${version}.tar.bz2"; - hash = "sha256-FFjLCMWF6unXJL7G8oErzAO76D7SlKRqeJeqqwGm8Vo="; + # Upstream uploaded a -1 tarball on the same release, remove on next release + url = "https://github.com/Gnucash/gnucash/releases/download/${version}/${pname}-${version}-1.tar.bz2"; + hash = "sha256-d0EWXW1lLqe0oehJjPQ5pWuBpcyLZTKRpZBU8jYqv8w="; }; nativeBuildInputs = [ @@ -74,8 +76,12 @@ stdenv.mkDerivation rec { ./0003-remove-valgrind.patch # this patch makes gnucash exec the Finance::Quote wrapper directly ./0004-exec-fq-wrapper.patch - # this patch removes the online_wiggle GncQuotes test - ./0005-remove-gncquotes-online-wiggle.patch + # this patch fixes a test that fails due to a type error, remove on next release + (fetchpatch { + name = "0005-utest-gnc-pricedb-fix.patch"; + url = "https://github.com/Gnucash/gnucash/commit/0bd556c581ac462ca41b3cb533323fc3587051e1.patch"; + hash = "sha256-k0ANZuOkWrtU4q380oDu/hC9PeGmujF49XEFQ8eCLGM="; + }) ]; # this needs to be an environment variable and not a cmake flag to suppress @@ -95,7 +101,7 @@ stdenv.mkDerivation rec { gappsWrapperArgs+=( # db drivers location --set GNC_DBD_DIR ${libdbiDrivers}/lib/dbd - # gnome settings schemas location on Nix + # gsettings schema location on Nix --set GSETTINGS_SCHEMA_DIR ${glib.makeSchemaPath "$out" "${pname}-${version}"} ) ''; @@ -108,6 +114,7 @@ stdenv.mkDerivation rec { # gnc-fq-* are cli utils written in Perl hence the extra wrapping postFixup = '' wrapProgram $out/bin/gnucash "''${gappsWrapperArgs[@]}" + wrapProgram $out/bin/gnucash-cli "''${gappsWrapperArgs[@]}" wrapProgram $out/bin/finance-quote-wrapper \ --prefix PERL5LIB : "${with perlPackages; makeFullPerlPath [ JSONParse FinanceQuote ]}" @@ -139,6 +146,7 @@ stdenv.mkDerivation rec { license = licenses.gpl2Plus; maintainers = with maintainers; [ domenkozar AndersonTorres rski nevivurn ]; platforms = platforms.unix; + mainProgram = "gnucash"; }; } # TODO: investigate Darwin support |