From: Peter Korsgaard <peter@korsgaard.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH] ccache: make default host-ccache cache dir fit for multi-user setups
Date: Fri, 07 Jul 2017 17:26:55 +0200 [thread overview]
Message-ID: <87lgo0w9mo.fsf@dell.be.48ers.dk> (raw)
In-Reply-To: <904fdb4b-2dd4-af9b-ac79-8e31cc554647@mind.be> (Arnout Vandecappelle's message of "Fri, 7 Jul 2017 17:18:11 +0200")
>>>>> "Arnout" == Arnout Vandecappelle <arnout@mind.be> writes:
Hi,
> I think Thomas's point is: ~/.br-ccache is fine, ~/foo/bar/directory is not
> fine, even if that is what was configured in the buildroot config from which the
> external toolchain was generated (and which is NOT the buildroot configuration
> used by the final user, otherwise this problem wouldn't even occur).
Well, it is a choice made by whoever built the sdk, just like the gcc
version and C library or whatever.
If it truly makes sense to make this configuable is another question. I
have never used that feature at least (but we have plenty of other
features that I also don't use).
> I think Thomas, like me, means that we should instead revert
> d93a0b402934309c632d4a825b7fe6183ce8c4c7.
That is also an option, but as we have been carrying this patch for > 3
years, there might be people using it.
> In fact, I think we should drop this Buildroot-specific patching entirely. As
> far as I can see, BR_CACHE_DIR was introduced to replace the normal CCACHE_DIR
> because way back when our ccache didn't reliably detect the compiler and would
> reuse object files that we actually created with a different toolchain. So the
> Buildroot-specific ccache would disable fingerprinting completely. Obviously, if
> it would then reuse the same cache directory as the normal ccache, there would
> be a huge risk that target ccache would use cached objects for the host...
> Nowadays we have the fingerprinting in place (which is hopefully still
> reliable), so the reason for have a separate cache dir is gone IMO. So I think
> we should just use CCACHE_DIR instead of BR_CACHE_DIR. BR2_CCACHE_DIR still
> makes sense, since you may want to encode a shared ccache in your Buildroot
> config. But I think it should default to empty, where empty means don't export
> CCACHE_DIR and rely on ccache's default.
Yes, I have also always been uneasy about these ccache patches - But I
normally don't use ccache, so I'm not sure how bullet proof the finger
printing is.
> Such a change, however, would first require a test to be set up. And testing
> ccache is decidedly non-trivial. Therefore it's a more long-term goal.
> Therefore, this patch makes sense after all. Indeed, if a user currently
> generates an SDK with the default configuration, it will definitely do the wrong
> thing (pointing to another user's br-ccache directory). So I'll change my weak
> NACK into a weak ACK.
Ok, thanks.
--
Bye, Peter Korsgaard
next prev parent reply other threads:[~2017-07-07 15:26 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-06 10:48 [Buildroot] [PATCH] ccache: make default host-ccache cache dir fit for multi-user setups Peter Korsgaard
2017-07-06 19:21 ` Thomas Petazzoni
2017-07-06 22:28 ` Peter Korsgaard
2017-07-07 7:28 ` Thomas Petazzoni
2017-07-07 9:48 ` Peter Korsgaard
2017-07-07 15:18 ` Arnout Vandecappelle
2017-07-07 15:26 ` Peter Korsgaard [this message]
2017-07-06 23:18 ` Arnout Vandecappelle
2017-07-07 6:50 ` Peter Korsgaard
2017-07-08 18:55 ` Peter Korsgaard
2017-07-19 13:49 ` Peter Korsgaard
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=87lgo0w9mo.fsf@dell.be.48ers.dk \
--to=peter@korsgaard.com \
--cc=buildroot@busybox.net \
/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