From d234c03de8e3d1851f8ca285c96847e4d6682403 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Romildo?= Date: Sun, 14 Nov 2021 10:28:03 -0300 Subject: [PATCH 1/2] paper-icon-theme: 2018-06-24 -> unstable-2020-03-12 --- pkgs/data/icons/paper-icon-theme/default.nix | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/pkgs/data/icons/paper-icon-theme/default.nix b/pkgs/data/icons/paper-icon-theme/default.nix index a8eb1a8736d6..9ab6fe1b5895 100644 --- a/pkgs/data/icons/paper-icon-theme/default.nix +++ b/pkgs/data/icons/paper-icon-theme/default.nix @@ -1,21 +1,20 @@ -{ lib, stdenv, fetchFromGitHub, meson, ninja, gtk3, python3, gnome, gnome-icon-theme, hicolor-icon-theme }: +{ lib, stdenv, fetchFromGitHub, meson, ninja, gtk3, gnome, gnome-icon-theme, hicolor-icon-theme }: stdenv.mkDerivation rec { pname = "paper-icon-theme"; - version = "2018-06-24"; + version = "unstable-2020-03-12"; src = fetchFromGitHub { owner = "snwh"; repo = pname; - rev = "c7cd013fba06dd8fd5cdff9f885520e2923266b8"; - sha256 = "0x45zkjnmbz904df63ph06npbm3phpgck4xwyymx8r8jgrfplk6v"; + rev = "aa3e8af7a1f0831a51fd7e638a4acb077a1e5188"; + sha256 = "0x6qzch4rrc8firb1dcf926j93gpqxvd7h6dj5wwczxbvxi5bd77"; }; nativeBuildInputs = [ meson ninja gtk3 - python3 ]; propagatedBuildInputs = [ @@ -26,10 +25,6 @@ stdenv.mkDerivation rec { dontDropIconThemeCache = true; - postPatch = '' - patchShebangs meson/post_install.py - ''; - postInstall = '' # The cache for Paper-Mono-Dark is missing gtk-update-icon-cache "$out"/share/icons/Paper-Mono-Dark; From fbbfc3edfa4a90743e0f0db179abb242da4c6a4c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Romildo?= Date: Sun, 14 Nov 2021 10:49:57 -0300 Subject: [PATCH 2/2] paper-icon-theme: replace duplicate files with symlinks This reduces considerably the space used by the package. --- pkgs/data/icons/paper-icon-theme/default.nix | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/pkgs/data/icons/paper-icon-theme/default.nix b/pkgs/data/icons/paper-icon-theme/default.nix index 9ab6fe1b5895..fc541f6e5b72 100644 --- a/pkgs/data/icons/paper-icon-theme/default.nix +++ b/pkgs/data/icons/paper-icon-theme/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchFromGitHub, meson, ninja, gtk3, gnome, gnome-icon-theme, hicolor-icon-theme }: +{ lib, stdenv, fetchFromGitHub, meson, ninja, gtk3, gnome, gnome-icon-theme, hicolor-icon-theme, jdupes }: stdenv.mkDerivation rec { pname = "paper-icon-theme"; @@ -15,6 +15,7 @@ stdenv.mkDerivation rec { meson ninja gtk3 + jdupes ]; propagatedBuildInputs = [ @@ -25,9 +26,16 @@ stdenv.mkDerivation rec { dontDropIconThemeCache = true; + # These fixup steps are slow and unnecessary for this package + dontPatchELF = true; + dontRewriteSymlinks = true; + postInstall = '' # The cache for Paper-Mono-Dark is missing gtk-update-icon-cache "$out"/share/icons/Paper-Mono-Dark; + + # replace duplicate files with symlinks + jdupes -l -r $out/share/icons ''; meta = with lib; {