[OE-core] [PATCH] ccache: Disable CCACHE_HASHDIR by default

Mike Crowe mac at mcrowe.com
Mon Mar 13 13:51:46 UTC 2017


On Monday 13 March 2017 at 13:33:27 +0000, Burton, Ross wrote:
> On 11 March 2017 at 16:54, Mike Crowe <mac at mcrowe.com> wrote:
> 
> > ccache apparently does this so that paths in the debug information will
> > always be correct. In an OE world these paths may already be missing or
> > incorrect due to rm_work or the use of a shared sstate cache, so it doesn't
> > seem as if we're losing much by disabling this feature.
> >
> 
> In an OE world we tell GCC to rewrite them to be target paths anyway, so
> this isn't a problem.  Maybe worth rewriting the commit message?
> 
> (see bitbake.conf, -fdebug-prefix-map)

I wasn't aware of that.

ccache does have some technology to detect this situation:

  Exception: The CWD will not be included in the hash if *base_dir* is set
  (and matches the CWD) and the compiler option *-fdebug-prefix-map* is
  used.

I think this means that if CCACHE_BASEDIR is set appropriately then it
wouldn't be necessary to set CCACHE_NOHASHDIR. (Looking at the ccache code,
I think that "matches the CWD" means "CWD is under *base_dir*" rather than
the two needing to be identical.)

I shall investigate why things weren't working correctly for us. In the
meantime I don't think my patch is yet proven to be doing the right thing.

Thanks.

Mike.



More information about the Openembedded-core mailing list