* [PATCH] gtk-icon-cache: don't call gtk-update-icon-cache on files
@ 2012-12-22 19:58 Martin Jansa
2012-12-22 20:14 ` Martin Jansa
0 siblings, 1 reply; 2+ messages in thread
From: Martin Jansa @ 2012-12-22 19:58 UTC (permalink / raw)
To: openembedded-core
* check if icondir is directory before calling gtk-update-icon-cache, like all other calls do
* fixes:
| > Executing update_icon_cache
| + chmod +x update_icon_cache
| + ./update_icon_cache
| gtk-update-icon-cache.real: Failed to open file /tmp-eglibc/work/qemuarm-oe-linux-gnueabi/shr-image-all/2.0-r20/rootfs/usr/share/icons/enjoy.png/.icon-theme.cache : Not a directory
| gtk-update-icon-cache.real: Failed to open file /tmp-eglibc/work/qemuarm-oe-linux-gnueabi/shr-image-all/2.0-r20/rootfs/usr/share/icons/monav.png/.icon-theme.cache : Not a directory
| gtk-update-icon-cache.real: Failed to open file /tmp-eglibc/work/qemuarm-oe-linux-gnueabi/shr-image-all/2.0-r20/rootfs/usr/share/icons/orrery.png/.icon-theme.cache : Not a directory
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
---
meta/classes/gtk-icon-cache.bbclass | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/meta/classes/gtk-icon-cache.bbclass b/meta/classes/gtk-icon-cache.bbclass
index f87a30f..7c7dd78 100644
--- a/meta/classes/gtk-icon-cache.bbclass
+++ b/meta/classes/gtk-icon-cache.bbclass
@@ -12,7 +12,9 @@ if [ "x$D" != "x" ]; then
gdk-pixbuf-query-loaders --update-cache
for icondir in $D/usr/share/icons/*/ ; do
- gtk-update-icon-cache -fqt $icondir
+ if [ -d $icondir ] ; then
+ gtk-update-icon-cache -fqt $icondir
+ fi
done
EOF
fi
--
1.8.0.2
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [PATCH] gtk-icon-cache: don't call gtk-update-icon-cache on files
2012-12-22 19:58 [PATCH] gtk-icon-cache: don't call gtk-update-icon-cache on files Martin Jansa
@ 2012-12-22 20:14 ` Martin Jansa
0 siblings, 0 replies; 2+ messages in thread
From: Martin Jansa @ 2012-12-22 20:14 UTC (permalink / raw)
To: openembedded-core
[-- Attachment #1: Type: text/plain, Size: 1912 bytes --]
On Sat, Dec 22, 2012 at 08:58:49PM +0100, Martin Jansa wrote:
> * check if icondir is directory before calling gtk-update-icon-cache, like all other calls do
> * fixes:
> | > Executing update_icon_cache
> | + chmod +x update_icon_cache
> | + ./update_icon_cache
> | gtk-update-icon-cache.real: Failed to open file /tmp-eglibc/work/qemuarm-oe-linux-gnueabi/shr-image-all/2.0-r20/rootfs/usr/share/icons/enjoy.png/.icon-theme.cache : Not a directory
> | gtk-update-icon-cache.real: Failed to open file /tmp-eglibc/work/qemuarm-oe-linux-gnueabi/shr-image-all/2.0-r20/rootfs/usr/share/icons/monav.png/.icon-theme.cache : Not a directory
> | gtk-update-icon-cache.real: Failed to open file /tmp-eglibc/work/qemuarm-oe-linux-gnueabi/shr-image-all/2.0-r20/rootfs/usr/share/icons/orrery.png/.icon-theme.cache : Not a directory
Be aware that you need to manually remove
$INTERCEPT_DIR/update_icon_cache
otherwise such broken script is kept forever
gtk_icon_cache_postinst() {
if [ "x$D" != "x" ]; then
if [ ! -f $INTERCEPT_DIR/update_icon_cache ]; then
cat << "EOF" > $INTERCEPT_DIR/update_icon_cache
>
> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
> ---
> meta/classes/gtk-icon-cache.bbclass | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/meta/classes/gtk-icon-cache.bbclass b/meta/classes/gtk-icon-cache.bbclass
> index f87a30f..7c7dd78 100644
> --- a/meta/classes/gtk-icon-cache.bbclass
> +++ b/meta/classes/gtk-icon-cache.bbclass
> @@ -12,7 +12,9 @@ if [ "x$D" != "x" ]; then
> gdk-pixbuf-query-loaders --update-cache
>
> for icondir in $D/usr/share/icons/*/ ; do
> - gtk-update-icon-cache -fqt $icondir
> + if [ -d $icondir ] ; then
> + gtk-update-icon-cache -fqt $icondir
> + fi
> done
> EOF
> fi
> --
> 1.8.0.2
>
--
Martin 'JaMa' Jansa jabber: Martin.Jansa@gmail.com
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 205 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2012-12-22 20:29 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-12-22 19:58 [PATCH] gtk-icon-cache: don't call gtk-update-icon-cache on files Martin Jansa
2012-12-22 20:14 ` Martin Jansa
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox