sstate/buildhistory: Fix plaindirs handling to occur before SSTATEPOSTINSTFUNCS
buildhistory is showing issues where plaindirs installed files (such as package
listings) are not reliably being handled with installs from sstate.
The reason is that plaindirs is being handled after SSTATEPOSTINSTFUNCS
instead of before it, meaning the files visible in a non-sstate accelerated
code run are different to show from an accelerated run.
This can be observed by the missing files lists for packages in buildhistory, both
in from scratch builds and in builds from sstate. In builds where sstate is installed
over an existing build directory, the files are present though, so there is a
determinism problem.
Fix this by moving the code into sstate_install, this is the only call
site for the funciton.
Since the move needs prepdir, move that as well as it's call site,
being careful to handle the two different definitions of SSTATE_INSTDIR. The
version originally in the function was obsolete and was causing the postinstfuncs
to run in an incorrect directory. The only user is buildhistory and it wasn't
sensitive to cwd however so this happened not to cause a problem. Fix the
code to use the correct location.
Signed-off-by:
Richard Purdie <richard.purdie@linuxfoundation.org>
Loading
Please register or sign in to comment