Closed belegdol closed 4 months ago
Looks like "CCACHE_NOHASHDIR": "1"
is sufficient, which at least makes implementation simple. What remains to be clarified is whether there is any impact on debug info files.
CCache is not used in any build system Fedora use, so this is very low priority for us. If you submit PR that set this variable (even for all builds) we will review and accept it. You can take example from https://github.com/rpm-software-management/mock/blob/main/mock/py/mockbuild/plugins/ccache.py#L56 and test if this helps.
Short description of the problem
This is a continuation of a discussion started on fedora-devel ML. Mock ccache plugin, as configured currently, only speeds up re-builds of exactly the same NEVR, due to the majority of packages including NEVR in the builddir. By default, the current working dir is included in the ccache hash, resulting in no cache hits. I have experimented (somewhat crudely) with
hash_dir
andbase_dir
options, and was successfully able to get ccache to find hits across builds. Here is the patch I used:There are two issues with these options:
Not sure if it a problem for rpm builds or if the debug info files even include the working dir
Output of
rpm -q mock
mock-5.6-3.fc40.test.noarch
Steps to reproduce issue
Command line used:
Any additional notes
Output of `mock --debug-config`