Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ccache support to build (via --enable-ccache configure option) #6805

Closed
pnkfelix opened this issue May 29, 2013 · 3 comments
Closed

Add ccache support to build (via --enable-ccache configure option) #6805

pnkfelix opened this issue May 29, 2013 · 3 comments

Comments

@pnkfelix
Copy link
Member

The current docs suggest that one should enable ccache by playing games with what gcc (and clang, etc) map to in one's PATH.

That is certainly one approach to the problem.

But I would prefer if it were not the only way to get the effect; I don't want to globally reroute my system's gcc/clang to ccache, and would prefer a configure option that makes our build Makefiles use the form of invoking ccache that passes along compiler as well.

I've hacked up a patch to do this on my system, so I'll assign this to myself.

@ghost ghost assigned pnkfelix May 29, 2013
@pnkfelix
Copy link
Member Author

(Note that even though the Makefile infrastructure will go away with #2237, that is orthogonal to whether we easily allow ccache to be substituted in.)

pnkfelix added a commit to pnkfelix/rust that referenced this issue May 29, 2013
…mpiler invocations with ccache to attempt to reuse common results, e.g. for LLVM (re)builds.
bors added a commit that referenced this issue May 29, 2013
…catamorphism

Fix #6805: add --enable-ccache configure option to prefix compiler invocations with `ccache` to attempt to reuse common results, e.g. for LLVM (re)builds.

The information at developer [Note-ccache](../../wiki/Note-ccache) and at [ccache and clang concerns](http://petereisentraut.blogspot.fr/2011/09/ccache-and-clang-part-2.html) were what drove my introduction of the `-Qunused-arguments` and `CCACHE_CPP2` options.  (Though I did confirm first-hand that at least the first really is necessary.)

Yes, one certainly can re-route how `gcc` and `clang` are resolved in one's PATH and use that as a way to invoke `ccache`.  But I personally do not want to introduce that change to my own PATH, and this seems like a small enough change that it does not hurt to add it, at least for now.  (I don't know what form it would take when we move over to `rustpkg`.)
@Aatch
Copy link
Contributor

Aatch commented May 30, 2013

Closed by #6813

@Aatch Aatch closed this as completed May 30, 2013
@pnkfelix
Copy link
Member Author

Hmm, my patch is not as effective as I had hoped.

My current hypothesis is that this is because our build process is including absolute paths in the preprocessor output (i.e. becauase the -Idir directives are using absolute paths for the dirs), and by default ccache will treat such files as different keys in its cache.

One way to fix this would be to make use of the CCACHE_BASEDIR environment variable. Another could be to use relative paths instead of absolute ones at appropriate steps in the build...

bors added a commit that referenced this issue May 30, 2013
…dir, r=catamorphism

Attempt to get reuse of common object code from multiple clones in different directories.

This is a followup to issue #6805.
@pnkfelix pnkfelix removed their assignment Jun 16, 2014
flip1995 pushed a commit to flip1995/rust that referenced this issue Mar 25, 2021
upper_case_acronyms: don't warn on public items

Fixes rust-lang#6803

changelog: upper_case_acronyms: ignore public items
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants