Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Laurentiu Palcu <laurentiu.palcu@intel.com>
To: openembedded-core@lists.openembedded.org
Subject: Re: [PATCH 3/5] package_rpm: export the native directory to the postinst scriptlets
Date: Sat, 04 Aug 2012 11:59:56 +0300	[thread overview]
Message-ID: <501CE48C.9090202@intel.com> (raw)
In-Reply-To: <501CD352.7080908@intel.com>



On 08/04/2012 10:46 AM, Laurentiu Palcu wrote:
> 
> 
> On 08/03/2012 11:25 PM, Mark Hatle wrote:
>> On 8/3/12 3:19 PM, Laurentiu Palcu wrote:
>>> Some postinst scriptlets test for the existence of certain files but
>>> have the paths hardcoded to the target's rootfs. This patch will allow
>>> us to run postinst scriptlets at do_rootfs time by calling native
>>> binaries.
>>>
>>> Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
>>> ---
>>>   meta/classes/package_rpm.bbclass |    1 +
>>>   1 file changed, 1 insertion(+)
>>>
>>> diff --git a/meta/classes/package_rpm.bbclass b/meta/classes/package_rpm.bbclass
>>> index 50e9b31..113b19c 100644
>>> --- a/meta/classes/package_rpm.bbclass
>>> +++ b/meta/classes/package_rpm.bbclass
>>> @@ -443,6 +443,7 @@ export D="${target_rootfs}"
>>>   export OFFLINE_ROOT="\$D"
>>>   export IPKG_OFFLINE_ROOT="\$D"
>>>   export OPKG_OFFLINE_ROOT="\$D"
>>> +export NATIVE_DIR="${STAGING_DIR_NATIVE}"
>>
>> Why is this needed?  Normally the host items run from the path (and should know 
>> how to access any related files they need), and ${D} points to the target rootfs 
>> directory for things needing full paths.
> Hmm, I think you're perfectly right... I needed it because the
> gdk-pixbuf postinst scriplet tested the existence of
> gtk-update-icon-cache binary but, now that you mentioned it, I realized
> it might work without it. Test the existence of the binary on target
> rootfs but run the native one from PATH.
However, I just remembered that the rpm packages are not installed in
dependency order... So, there might be packages, that need
gtk-update-icon-cache, installed before libgtk+ is installed. In this
case, the postinst scriptlets that test the existence of the binary on
the target rootfs will fail at do_roofts time... Unless a solution is
found to install the rpm packages in dependency order. BTW, is this
planned to be fixed?

Laurentiu
> 
> Thanks for the tip,
> Laurentiu
>>
>> --Mark
>>
>>>
>>>   \$2 \$1/\$3 \$4
>>>   if [ \$? -ne 0 ]; then
>>>
>>
>>
>> _______________________________________________
>> Openembedded-core mailing list
>> Openembedded-core@lists.openembedded.org
>> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core
>>
> 
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core
> 



  reply	other threads:[~2012-08-04  9:11 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-03 20:19 [PATCH 0/5] Run postinst scriptlets at do_rootfs time Laurentiu Palcu
2012-08-03 20:19 ` [PATCH 1/5] gtk+: enable gtk+-native Laurentiu Palcu
2012-08-03 20:19 ` [PATCH 2/5] sato-icon-theme: make postinst scriplet run at do_rootfs time Laurentiu Palcu
2012-08-06  9:28   ` Burton, Ross
2012-08-03 20:19 ` [PATCH 3/5] package_rpm: export the native directory to the postinst scriptlets Laurentiu Palcu
2012-08-03 20:25   ` Mark Hatle
2012-08-04  7:46     ` Laurentiu Palcu
2012-08-04  8:59       ` Laurentiu Palcu [this message]
2012-08-04 14:41         ` Mark Hatle
2012-08-03 20:19 ` [PATCH 4/5] gtk-icon-cache: call postinst scriplet at do_rootfs time Laurentiu Palcu
2012-08-03 23:22   ` Andreas Müller
2012-08-04  7:49     ` Laurentiu Palcu
2012-08-04  9:29       ` Andreas Müller
2012-08-04 14:01         ` Laurentiu Palcu
2012-08-04 17:14           ` Koen Kooi
2012-08-04 19:37             ` Andreas Müller
2012-08-04 19:51               ` Khem Raj
2012-08-04 19:56                 ` Martin Jansa
2012-08-04 20:25                   ` Andreas Müller
2012-08-05 16:58                 ` Laurentiu Palcu
2012-08-05 22:30                   ` Andreas Müller
2012-08-05 22:49                     ` Andreas Müller
2012-08-06  7:48                       ` Laurentiu Palcu
2012-08-06  8:10                         ` Andreas Müller
2012-08-06  9:18                           ` Laurentiu Palcu
2012-08-06  9:35                             ` Burton, Ross
2012-08-06  9:36                             ` Andreas Müller
2012-08-06 18:50                             ` Andreas Müller
2012-08-05 11:50               ` Koen Kooi
2012-08-04 10:24   ` Koen Kooi
2012-08-03 20:19 ` [PATCH 5/5] gdk-pixbuf: allow postinst scriplet to be called " Laurentiu Palcu

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=501CE48C.9090202@intel.com \
    --to=laurentiu.palcu@intel.com \
    --cc=openembedded-core@lists.openembedded.org \
    /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