[yocto] stupid question about post-installation scripts

Bryan Evenson bevenson at melinkcorp.com
Mon Nov 25 07:56:17 PST 2013


Robert,

That's how it works in my experience.  I have some packages for my system that have a postinst piece that needs to run during image creation, and other pieces that need to run only on a package upgrade.  By checking whether "x${D}" = "${D}", I am filtering out whether the postinst script is running during image creation or on the actual hardware.  Been working great so far.

-Bryan

> -----Original Message-----
> From: yocto-bounces at yoctoproject.org [mailto:yocto-
> bounces at yoctoproject.org] On Behalf Of Rifenbark, Scott M
> Sent: Monday, November 25, 2013 10:22 AM
> To: Robert P. J. Day
> Cc: Yocto discussion list
> Subject: [yocto] FW: stupid question about post-installation scripts
> 
> Robert,
> 
> I don't know... I am forwarding to the discussion list.
> 
> Scott
> 
> >-----Original Message-----
> >From: Robert P. J. Day [mailto:rpjday at crashcourse.ca]
> >Sent: Sunday, November 24, 2013 2:37 AM
> >To: Rifenbark, Scott M
> >Subject: stupid question about post-installation scripts
> >
> >
> >  when one defines pkg_postinst scripts, are those scripts invoked at
> >*both* root filesystem creation time and first boot time? so that one
> >needs to manually check the value of ${D} to decide whether to run
> >them, say, at first boot time?
> >
> >  i'm reading the section here:
> >
> >http://www.yoctoproject.org/docs/latest/dev-manual/dev-
> >manual.html#post-installation-scripts
> >
> >and i know i've seen elsewhere scripts explicitly checking the value
> of
> >the ${D} prefix to determine when they're being invoked. it *seems*
> >like that's what's happening, but if that's the case, it can probably
> be said much more clearly.
> >
> >rday
> _______________________________________________
> yocto mailing list
> yocto at yoctoproject.org
> https://lists.yoctoproject.org/listinfo/yocto



More information about the yocto mailing list