1
0
mirror of https://github.com/dguglielmi/sunny-overlay.git synced 2025-12-06 11:42:40 +01:00
Files
sunny-overlay/app-misc/piper/files/piper-0.2.900-do-not-generate-icon-cache-when-destdir-is-set.patch

42 lines
1.3 KiB
Diff

From bb355b9d2991fff8f06f2dfe7fa46ecedef6a19c Mon Sep 17 00:00:00 2001
From: Ikey Doherty <ikey@solus-project.com>
Date: Thu, 19 Oct 2017 15:31:32 +0100
Subject: [PATCH 21/30] Do not generate icon-cache when DESTDIR is set
This ensures that the icon cache will be generated when installed locally,
but will also make sure that we don't generate one when DESTDIR is set.
This helps with packaging, where packages should never provide the duplicate
"icon-theme.cache" file inside the package.
This is based around the meson build system implemented by @TingPing in
the gnome-twitch project.
Signed-off-by: Ikey Doherty <ikey@solus-project.com>
---
meson_install.sh | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)
diff --git a/meson_install.sh b/meson_install.sh
index d004eb7..e5aa42a 100644
--- a/meson_install.sh
+++ b/meson_install.sh
@@ -1,7 +1,11 @@
#!/usr/bin/env sh
-# Update icon cache
-gtk-update-icon-cache -f -t ${DESTDIR}/${MESON_INSTALL_PREFIX}/share/icons/hicolor
+if [ -z $DESTDIR ]; then
+ PREFIX=${MESON_INSTALL_PREFIX:-/usr}
-# Install new schemas
-#glib-compile-schemas ${DESTDIR}/${MESON_INSTALL_PREFIX}/share/glib-2.0/schemas/
+ # Update icon cache
+ gtk-update-icon-cache -f -t $PREFIX/share/icons/hicolor
+
+ # Install new schemas
+ #glib-compile-schemas $PREFIX/share/glib-2.0/schemas/
+fi
--
2.16.1