4 |
- |
1 |
# Use ccache by default. Users who don't want that can setenv the
|
|
|
2 |
# CCACHE_DISABLE environment variable in their personal profile.
|
|
|
3 |
|
|
|
4 |
if ( "$path" !~ */usr/lib64/ccache* ) then
|
|
|
5 |
set path = ( /usr/lib64/ccache $path )
|
|
|
6 |
endif
|
|
|
7 |
|
|
|
8 |
# If /var/cache/ccache is writable, use a shared cache there, except for root.
|
|
|
9 |
# Users who don't want that even if they have the write permission can setenv
|
|
|
10 |
# the CCACHE_DIR environment variable to another location and possibly unsetenv
|
|
|
11 |
# the CCACHE_UMASK environment variable in their personal profile.
|
|
|
12 |
|
|
|
13 |
if ( $?CCACHE_DIR ) then
|
|
|
14 |
if ( ! -w "$CCACHE_DIR" ) then
|
|
|
15 |
# Reset broken settings maybe inherited when switching users (#651023).
|
|
|
16 |
unsetenv CCACHE_DIR
|
|
|
17 |
unsetenv CCACHE_UMASK
|
|
|
18 |
endif
|
|
|
19 |
else if ( $uid != 0 ) then
|
|
|
20 |
if ( -w /var/cache/ccache && -d /var/cache/ccache ) then
|
|
|
21 |
# Set up the shared cache.
|
|
|
22 |
setenv CCACHE_DIR /var/cache/ccache
|
|
|
23 |
setenv CCACHE_UMASK 002
|
|
|
24 |
unsetenv CCACHE_HARDLINK
|
|
|
25 |
endif
|
|
|
26 |
endif
|
|
|
27 |
|
|
|
28 |
setenv CCACHE_HASHDIR
|