From 80969cc4ec0ac4aa1bcb677263cdd0ad2085158f Mon Sep 17 00:00:00 2001 From: Rodney Lorrimar Date: Wed, 12 May 2021 21:13:05 +1000 Subject: [PATCH 1/3] haskellPackages.taffybar: fix build Add patches to allow building with gi-gdkpixbuf_2_0_26 Upstream PRs: - https://github.com/taffybar/gtk-sni-tray/pull/25 - https://github.com/taffybar/taffybar/pull/507 --- .../haskell-modules/configuration-common.nix | 14 ++++++++++++++ .../configuration-hackage2nix/broken.yaml | 1 - .../transitive-broken.yaml | 1 - .../haskell-modules/hackage-packages.nix | 3 --- 4 files changed, 14 insertions(+), 5 deletions(-) diff --git a/pkgs/development/haskell-modules/configuration-common.nix b/pkgs/development/haskell-modules/configuration-common.nix index a7a72f09cf8..473c2a45bfc 100644 --- a/pkgs/development/haskell-modules/configuration-common.nix +++ b/pkgs/development/haskell-modules/configuration-common.nix @@ -1271,6 +1271,20 @@ self: super: { # Created upstream PR @ https://github.com/ghcjs/jsaddle/pull/119 jsaddle-webkit2gtk = appendPatch super.jsaddle-webkit2gtk ./patches/jsaddle-webkit2gtk.patch; + # 2021-05-12: gi-gdkpixbuf_2_0_26 fix + # https://github.com/taffybar/gtk-sni-tray/pull/25 + gtk-sni-tray = appendPatch super.gtk-sni-tray (pkgs.fetchpatch { + url = "https://github.com/taffybar/gtk-sni-tray/pull/25/commits/4afd84654cb3f2bd2bb7d39451706c5914fd3cdf.patch"; + sha256 = "1xjxlh58vnykqsjq4qw8mliq3gk17mwxi4h9z8dvjyav8zqg05rn"; + }); + + # 2021-05-12: gi-gdkpixbuf_2_0_26 fix + # https://github.com/taffybar/taffybar/pull/507 + taffybar = appendPatch super.taffybar (pkgs.fetchpatch { + url = "https://github.com/taffybar/taffybar/pull/507/commits/14a650d0954000cbd2cb1018a2f3bcd40ecb564f.patch"; + sha256 = "01rm8zida5858j5r0mw7bpmv24b03mb3rw34lbkaw3i7g62bx3a0"; + }); + # Missing -Iinclude parameter to doc-tests (pull has been accepted, so should be resolved when 0.5.3 released) # https://github.com/lehins/massiv/pull/104 massiv = dontCheck super.massiv; diff --git a/pkgs/development/haskell-modules/configuration-hackage2nix/broken.yaml b/pkgs/development/haskell-modules/configuration-hackage2nix/broken.yaml index 256857b033c..5419e3f16e3 100644 --- a/pkgs/development/haskell-modules/configuration-hackage2nix/broken.yaml +++ b/pkgs/development/haskell-modules/configuration-hackage2nix/broken.yaml @@ -1699,7 +1699,6 @@ broken-packages: - gtk2hs-rpn - gtk3-mac-integration - gtkglext - - gtk-sni-tray - gtksourceview2 - gtksourceview3 - gtk-toy diff --git a/pkgs/development/haskell-modules/configuration-hackage2nix/transitive-broken.yaml b/pkgs/development/haskell-modules/configuration-hackage2nix/transitive-broken.yaml index 5e6f9510011..e37785a6795 100644 --- a/pkgs/development/haskell-modules/configuration-hackage2nix/transitive-broken.yaml +++ b/pkgs/development/haskell-modules/configuration-hackage2nix/transitive-broken.yaml @@ -2886,7 +2886,6 @@ dont-distribute-packages: - systemstats - t3-client - ta - - taffybar - tagged-list - tagged-th - tagsoup-navigate diff --git a/pkgs/development/haskell-modules/hackage-packages.nix b/pkgs/development/haskell-modules/hackage-packages.nix index 472730a45f1..5e934b23f92 100644 --- a/pkgs/development/haskell-modules/hackage-packages.nix +++ b/pkgs/development/haskell-modules/hackage-packages.nix @@ -111794,8 +111794,6 @@ self: { platforms = [ "aarch64-linux" "armv7l-linux" "i686-linux" "x86_64-linux" ]; - hydraPlatforms = lib.platforms.none; - broken = true; }) {inherit (pkgs) gtk3;}; "gtk-strut" = callPackage @@ -252598,7 +252596,6 @@ self: { platforms = [ "aarch64-linux" "armv7l-linux" "i686-linux" "x86_64-linux" ]; - hydraPlatforms = lib.platforms.none; }) {inherit (pkgs) gtk3;}; "tag-bits" = callPackage From c46059f732af696357e59043a771282a610130eb Mon Sep 17 00:00:00 2001 From: Rodney Lorrimar Date: Wed, 12 May 2021 22:15:17 +1000 Subject: [PATCH 2/3] taffybar: restore ability to override ghcWithPackages arg --- .../window-managers/taffybar/default.nix | 15 ++++++++++++--- pkgs/top-level/all-packages.nix | 4 +++- 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/window-managers/taffybar/default.nix b/pkgs/applications/window-managers/taffybar/default.nix index da495606930..7d9e5f9c1cb 100644 --- a/pkgs/applications/window-managers/taffybar/default.nix +++ b/pkgs/applications/window-managers/taffybar/default.nix @@ -1,7 +1,7 @@ -{ lib, stdenv, haskellPackages, makeWrapper, packages ? (x: []) }: +{ lib, stdenv, ghcWithPackages, taffybar, makeWrapper, packages ? (x: []) }: let - taffybarEnv = haskellPackages.ghc.withPackages (self: [ + taffybarEnv = ghcWithPackages (self: [ self.taffybar ] ++ packages self); in stdenv.mkDerivation { @@ -15,5 +15,14 @@ in stdenv.mkDerivation { --set NIX_GHC "${taffybarEnv}/bin/ghc" ''; - inherit (haskellPackages.taffybar) meta; + # Trivial derivation + preferLocalBuild = true; + allowSubstitutes = false; + + # For hacking purposes + passthru.env = taffybarEnv; + buildInputs = [ taffybarEnv ]; + shellHook = "eval $(egrep ^export ${taffybarEnv}/bin/ghc)"; + + inherit (taffybar) meta; } diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index e7cfe7eaf95..f126e817b6d 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -26320,7 +26320,9 @@ in # customConfig = builtins.readFile ./tabbed.config.h; }; - taffybar = callPackage ../applications/window-managers/taffybar {}; + taffybar = callPackage ../applications/window-managers/taffybar { + inherit (haskellPackages) ghcWithPackages taffybar; + }; tagainijisho = callPackage ../applications/office/tagainijisho {}; From a7d76a6cf03c8ed1034b966684100626de672e20 Mon Sep 17 00:00:00 2001 From: Rodney Lorrimar Date: Wed, 12 May 2021 22:21:17 +1000 Subject: [PATCH 3/3] haskellPackages.taffybar: add rvl to meta.maintainers Add myself as a "maintainer" of taffybar, and also arbtt and lentil, for which I have made build fixes in the past. --- .../haskell-modules/configuration-hackage2nix/main.yaml | 4 ++++ pkgs/development/haskell-modules/hackage-packages.nix | 3 +++ 2 files changed, 7 insertions(+) diff --git a/pkgs/development/haskell-modules/configuration-hackage2nix/main.yaml b/pkgs/development/haskell-modules/configuration-hackage2nix/main.yaml index e1031bc7255..1fb67026d11 100644 --- a/pkgs/development/haskell-modules/configuration-hackage2nix/main.yaml +++ b/pkgs/development/haskell-modules/configuration-hackage2nix/main.yaml @@ -233,6 +233,10 @@ package-maintainers: - hinit bdesham: - pinboard-notes-backup + rvl: + - taffybar + - arbtt + - lentil unsupported-platforms: Allure: [ x86_64-darwin ] diff --git a/pkgs/development/haskell-modules/hackage-packages.nix b/pkgs/development/haskell-modules/hackage-packages.nix index 5e934b23f92..edf0d51783e 100644 --- a/pkgs/development/haskell-modules/hackage-packages.nix +++ b/pkgs/development/haskell-modules/hackage-packages.nix @@ -32045,6 +32045,7 @@ self: { ]; description = "Automatic Rule-Based Time Tracker"; license = lib.licenses.gpl2Only; + maintainers = with lib.maintainers; [ rvl ]; }) {}; "arcgrid" = callPackage @@ -160371,6 +160372,7 @@ self: { ]; description = "frugal issue tracker"; license = lib.licenses.gpl3Only; + maintainers = with lib.maintainers; [ rvl ]; }) {}; "lenz" = callPackage @@ -252596,6 +252598,7 @@ self: { platforms = [ "aarch64-linux" "armv7l-linux" "i686-linux" "x86_64-linux" ]; + maintainers = with lib.maintainers; [ rvl ]; }) {inherit (pkgs) gtk3;}; "tag-bits" = callPackage