On 24-02-23, Richard Purdie wrote:
> On Fri, 2024-02-23 at 14:01 +0100, Marco Felsch wrote:
> > On 24-02-23, Richard Purdie wrote:
> > > On Fri, 2024-02-23 at 13:10 +0100, Marco Felsch wrote:
> > > > The fetch stage should always start with a clean ${S} directory
> > > > to
> > > > not
> > > > try to compile leftovers from previous builds.
> > > > 
> > > > Signed-off-by: Marco Felsch <[email protected]>
> > > > ---
> > > >  meta/classes-recipe/devicetree.bbclass | 2 ++
> > > >  1 file changed, 2 insertions(+)
> > > > 
> > > > diff --git a/meta/classes-recipe/devicetree.bbclass
> > > > b/meta/classes-
> > > > recipe/devicetree.bbclass
> > > > index bd50d7fa1d38..655460a9dbef 100644
> > > > --- a/meta/classes-recipe/devicetree.bbclass
> > > > +++ b/meta/classes-recipe/devicetree.bbclass
> > > > @@ -77,6 +77,8 @@ python () {
> > > >          d.appendVarFlag("do_compile", "depends", "
> > > > virtual/kernel:do_configure")
> > > >  }
> > > >  
> > > > +do_fetch[cleandirs] = "${S}"
> > > > +
> > > >  def expand_includes(varname, d):
> > > >      import glob
> > > >      includes = set()
> > > > 
> > > 
> > > This doesn't make sense. do_fetch works with the fetcher in
> > > directories
> > > outside WORKDIR. The sources only become available at do_unpack.
> > > The
> > > correct task would therefore be unpack.
> > 
> > Good to know, what I inspect is that old dts(i) files are still
> > present
> > once I adapted the SRC_URI path e.g:
> > 
> > SRC_URI = "a.dts b.dts"
> > 
> > to
> > 
> > SRC_URI = "b.dts"
> > 
> > and so this class tries to compile both, albeit I explicite removed
> > a.dts from SRC_URI.
> 
> This is a known problem, I thought there was an open bug for it but I
> can't seem to find it right now.
> 
> Basically the problem is that the fetcher can't know what it previously
> placed during do_unpack and know what it needs to clean up. Deleting
> the contents of ${S} sounds straight forward but in reality, it isn't
> quite that simple, particularly due to S = ${WORKDIR} that some recipes
> use.
> 
> Longer term the plan is to drop support for S = ${WORKDIR} and then we
> can simplify things but nobody has got around to doing that work yet.

Okay, thanks for input. In that case I will wait and notice it as known
bug.

Regards,
  Marco
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#196084): 
https://lists.openembedded.org/g/openembedded-core/message/196084
Mute This Topic: https://lists.openembedded.org/mt/104526882/21656
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to