diff options
-rw-r--r-- | meta/classes/ccache.bbclass | 10 | ||||
-rw-r--r-- | meta/conf/ccache.conf | 11 |
2 files changed, 9 insertions, 12 deletions
diff --git a/meta/classes/ccache.bbclass b/meta/classes/ccache.bbclass index 262db6672c..7c42e66bdf 100644 --- a/meta/classes/ccache.bbclass +++ b/meta/classes/ccache.bbclass | |||
@@ -44,16 +44,6 @@ export CCACHE_CONFIGPATH ?= "${COREBASE}/meta/conf/ccache.conf" | |||
44 | 44 | ||
45 | export CCACHE_DIR ?= "${CCACHE_TOP_DIR}/${MULTIMACH_TARGET_SYS}/${PN}" | 45 | export CCACHE_DIR ?= "${CCACHE_TOP_DIR}/${MULTIMACH_TARGET_SYS}/${PN}" |
46 | 46 | ||
47 | # Fixed errors: | ||
48 | # ccache: error: Failed to create directory /run/user/0/ccache-tmp: Permission denied | ||
49 | export CCACHE_TEMPDIR ?= "${CCACHE_DIR}/tmp" | ||
50 | |||
51 | # We need to stop ccache considering the current directory or the | ||
52 | # debug-prefix-map target directory to be significant when calculating | ||
53 | # its hash. Without this the cache would be invalidated every time | ||
54 | # ${PV} or ${PR} change. | ||
55 | export CCACHE_NOHASHDIR ?= "1" | ||
56 | |||
57 | python() { | 47 | python() { |
58 | """ | 48 | """ |
59 | Enable ccache for the recipe | 49 | Enable ccache for the recipe |
diff --git a/meta/conf/ccache.conf b/meta/conf/ccache.conf index 499e5327b8..377eb42196 100644 --- a/meta/conf/ccache.conf +++ b/meta/conf/ccache.conf | |||
@@ -1,7 +1,14 @@ | |||
1 | max_size = 0 | ||
2 | |||
3 | # Avoid spurious cache misses caused by recipe sysroot creation: Creating a | 1 | # Avoid spurious cache misses caused by recipe sysroot creation: Creating a |
4 | # recipe sysroot hardlinks all dependent files into place. Hardlinking updates | 2 | # recipe sysroot hardlinks all dependent files into place. Hardlinking updates |
5 | # the file's ctime which in turn interferes with ccache's include_file_ctime | 3 | # the file's ctime which in turn interferes with ccache's include_file_ctime |
6 | # check. | 4 | # check. |
7 | sloppiness = include_file_ctime | 5 | sloppiness = include_file_ctime |
6 | |||
7 | # We need to stop ccache considering the current directory or the | ||
8 | # debug-prefix-map target directory to be significant when calculating | ||
9 | # its hash. Without this the cache would be invalidated every time | ||
10 | # ${PV} or ${PR} change. | ||
11 | hash_dir = false | ||
12 | |||
13 | # If ccache runs under pseudo it will try to create files in /run/user/0/ccache-tmp | ||
14 | temporary_dir = $CCACHE_DIR/tmp | ||