Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Laurentiu Palcu <laurentiu.palcu@intel.com>
To: Khem Raj <raj.khem@gmail.com>
Cc: openembedded-core@lists.openembedded.org
Subject: Re: [RFC 5/7] gdk-pixbuf: generate the pixbuf loader's cache ar rootfs time
Date: Wed, 19 Sep 2012 18:29:56 +0300	[thread overview]
Message-ID: <5059E4F4.3040703@intel.com> (raw)
In-Reply-To: <CAMKF1soHduPtpm5rP8PGDUZVU=p9rV0FbJYtQsTbvOQA38sWSA@mail.gmail.com>



On 09/19/2012 04:30 PM, Khem Raj wrote:
> On Wed, Sep 19, 2012 at 4:49 AM, Laurentiu Palcu
> <laurentiu.palcu@intel.com> wrote:
>> This will generate the loaders.cache file for pixbuf, at rootfs time.
>>
>> Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
>> ---
>>  meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.24.1.bb |   24 ++++++++++++--------
>>  1 file changed, 14 insertions(+), 10 deletions(-)
>>
>> diff --git a/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.24.1.bb b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.24.1.bb
>> index 99f6cb4..c4afb97 100644
>> --- a/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.24.1.bb
>> +++ b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.24.1.bb
>> @@ -57,18 +57,22 @@ FILES_${PN}-dbg += " \
>>
>>  postinst_pixbufloader () {
>>  if [ "x$D" != "x" ]; then
>> -    exit 1
>> +# Update the target's pixbuf loader's cache. Since the native binary will
>> +# throw an error if the shared objects do not belong to the same ELF class,
>> +# we trick the gdk-pixbuf-query-loaders into scanning the native shared
>> +# objects and then we remove the NATIVE_ROOT prefix from the paths in
>> +# loaders.cache.
>> +gdk-pixbuf-query-loaders $(find $D/${libdir}/gdk-pixbuf-2.0/2.10.0/loaders \
>> +        -name *.so | sed -e "s:$D:$NATIVE_ROOT:g") > \
>> +        $D/${libdir}/gdk-pixbuf-2.0/2.10.0/loaders.cache || exit 1
>> +
>> +sed -i -e "s:$NATIVE_ROOT:/:g" $D/${libdir}/gdk-pixbuf-2.0/2.10.0/loaders.cache
>> +
> 
> 
> 
> gdk-pixbuf-2.0/2.10.0 seems to be quite hardcoded. Can it be converted
> into something more general may be use wildcard appropriately ?
I will investigate and see if I can find a more generic solution.
Basically, I just wanted to be consistent with what was already there.
I'll see what I can do.

Thanks,
Laurentiu
> 
>> +exit 0
>>  fi
>>
>> -GDK_PIXBUF_MODULEDIR=${libdir}/gdk-pixbuf-2.0/${LIBV}/loaders gdk-pixbuf-query-loaders --update-cache
>> -
>> -if [ -x ${bindir}/gtk-update-icon-cache ] && [ -d ${datadir}/icons ]; then
>> -    for icondir in /usr/share/icons/*; do
>> -        if [ -d ${icondir} ]; then
>> -            gtk-update-icon-cache -t -q ${icondir}
>> -        fi
>> -    done
>> -fi
>> +# Update the pixbuf loaders in case they haven't been registered yet
>> +GDK_PIXBUF_MODULEDIR=${libdir}/gdk-pixbuf-2.0/2.10.0/loaders gdk-pixbuf-query-loaders --update-cache
>>  }
>>
>>  PACKAGES_DYNAMIC += "gdk-pixbuf-loader-*"
>> --
>> 1.7.9.5
>>
>>
>> _______________________________________________
>> Openembedded-core mailing list
>> Openembedded-core@lists.openembedded.org
>> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core



  reply	other threads:[~2012-09-19 15:42 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-09-19 11:49 [RFC 0/7] Postinstall improvements Laurentiu Palcu
2012-09-19 11:49 ` [RFC 1/7] gtk+: enable gtk+-native Laurentiu Palcu
2012-09-19 11:49 ` [RFC 2/7] image.bbclass: run postinst scripts once, at rootfs time Laurentiu Palcu
2012-09-19 15:14   ` Burton, Ross
2012-09-19 15:45     ` Laurentiu Palcu
2012-09-19 15:50       ` Burton, Ross
2012-09-19 17:12         ` Laurentiu Palcu
2012-09-20 12:25   ` Richard Purdie
2012-09-19 11:49 ` [RFC 3/7] rootfs generation: export two new variables to postinst scriptlets Laurentiu Palcu
2012-09-19 11:49 ` [RFC 4/7] gtk-icon-cache: run the icon generation at rootfs time Laurentiu Palcu
2012-09-19 13:28   ` Khem Raj
2012-09-19 13:38     ` Burton, Ross
2012-09-19 15:26       ` Laurentiu Palcu
2012-09-19 11:49 ` [RFC 5/7] gdk-pixbuf: generate the pixbuf loader's cache ar " Laurentiu Palcu
2012-09-19 13:30   ` Khem Raj
2012-09-19 15:29     ` Laurentiu Palcu [this message]
2012-09-19 11:49 ` [RFC 6/7] sato-icon-theme: make use of the gtk-icon-cache postinst scriptlet Laurentiu Palcu
2012-09-19 13:36   ` Burton, Ross
2012-09-19 15:30     ` Laurentiu Palcu
2012-09-19 11:49 ` [RFC 7/7] postinst changes: bump PR to all recipes inheriting gnome and gtk-icon-cache Laurentiu Palcu
     [not found] ` <CALbNGRTCyvfZFYHx6bKV8oVDJWH3X0tj1DHSJm9CkvT4xY2f7A@mail.gmail.com>
     [not found]   ` <5059E5C3.2080603@intel.com>
2012-09-20 15:38     ` [RFC 0/7] Postinstall improvements Andreas Müller
2012-09-20 16:12       ` Andreas Müller
2012-09-20 18:15         ` Laurentiu Palcu
2012-09-20 20:54           ` Martin Jansa
2012-09-26  7:09         ` Laurentiu Palcu
2012-09-26  7:41           ` Andreas Müller
2012-10-03 23:37             ` Andreas Müller
2012-10-04 19:16               ` Andreas Müller
2012-10-05  6:39                 ` Laurentiu Palcu
2012-10-05 20:43                   ` Andreas Müller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5059E4F4.3040703@intel.com \
    --to=laurentiu.palcu@intel.com \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=raj.khem@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox