You are not logged in.
Pages: 1
Hii, I am using ccache and not sure its working right.
If i add a symbolic link from /bin/gcc to /usr/bin/ccache.
and then run gcc then it works?
I get the reguler gcc "gcc: no input files", but how do I know if ccache is on?
:?:
Offline
compile something new and then look for newly created files in the cache?
Offline
You should NOT symlink ccache to gcc!! you should instead use envirement variable
export CC="ccache gcc"
export CPP="ccache cpp"
export CXX="ccache g++"[My Blog] | [My Repo] | [My AUR Packages]
Offline
Why not doing a symbol link?
Can you please explain me?
in there site it is written like this
Offline
But it's written in Wiki to set a variable ![]()
Offline
afaik, makepkg will automatically use it, whether or not you have those variables set.
iphitus
Offline
@iphitus no that's not true, to make makepkg use it, u must add those to /etc/makepkg.conf, this is confirmed because once i had troubles compiling a package (don't recall it) and ccache was the problem i just removed those lines and ran makepkg again
[My Blog] | [My Repo] | [My AUR Packages]
Offline
_Gandalf_; makepkg definitely uses ccache when it's installed.
theres no way under the sun my computer can compile an entire kernel in ~5 minutes. In the meantime too, ~/.ccache is filling up with files from all my makepkg's. At the same time, there is no reference to it in makepkg.conf.
in /usr/bin/makepkg:
if [ "$NOCCACHE" = "0" ]; then
[ -d /usr/lib/ccache/bin ] && export PATH=/usr/lib/ccache/bin:$PATH
fiand NOCCACHE=0 is the default. It isnt mentioned in makepkg.conf.
So yeah, makepkg is definitely using ccache.
iphitus
Offline
iphitus, hmmm that's odd, coz i can export manuall CC to gcc and i see "gcc etc...". and i can export "CC=ccahe gcc" and then i can see "ccache gcc etc..." while makepkg is compiling, what u said above is just adding ccache bin dir to PATH but it's not exporting CC envirement variables therefore ccache is not used.... I'm not sure if what am saying is true or false but i know for sure that sometimes compilation fails i just turn off ccache and it works..
[My Blog] | [My Repo] | [My AUR Packages]
Offline
that wiki page applies to compiling anything. when using makepkg, you dont need to do that.
ccache is DEFINITELY used by makepkg, when it is installed. ask tpowa or neotuli.
trust me, theres no other way tpowa and my kernel compile times went down from 30 minutes to ~5.
iphitus
Offline
Does this work?
in .bashrc
alias gcc='ccache gcc'
alias cpp='ccache cpp'
alias g++='ccache g++'I removed my sig, cause i select the flag, the flag often the target of enemy.
SAR brain-tumor
[img]http://img91.imageshack.us/img91/460/cellphonethumb0ff.jpg[/img]
Offline
not every Makefile uses GCC,CPP,G++ variables, so this unstandard Makefiles won't use ccache.
Offline
Pages: 1