Bump to 4.8.3
[platform/upstream/ccache.git] / doc / NEWS.adoc
1 = Ccache news
2
3 == Ccache 4.8.3
4
5 Release date: 2023-08-29
6
7 === Bug fixes
8
9 - Fixed various problems with parsing of MSVC response file (`.rsp`). +
10   [small]#_[contributed by Jiri Hörner]_#
11
12 - Fixed handling of NVCC `-Xcompiler` and `--Werror` options. +
13   [small]#_[contributed by Andrew Hardin]_#
14
15 - Fixed bookkeeping of files when hard linking or file cloning is enabled. In
16   ccache 4.8–4.8.2 this could result in incorrect size/count statistics after
17   automatic or explicit cleanup. +
18   [small]#_[contributed by Joel Rosdahl]_#
19
20
21 === Build improvements
22
23 - Made a workaround for GCC 12.3 bug 109241 where GCC fails to compile ccache. +
24   [small]#_[contributed by Joel Rosdahl]_#
25
26 - Upgraded to xxHash 0.8.2, which fixes compilation of ccache with GCC 12 and
27   `-Og`. +
28   [small]#_[contributed by Joel Rosdahl]_#
29
30
31 == Ccache 4.8.2
32
33 Release date: 2023-06-12
34
35
36 === Bug fixes
37
38 - Fixed parsing of Windows drive letter in file URLs for remote storage. +
39   [small]#_[contributed by Joel Rosdahl]_#
40
41 - Fixed a bug affecting depend mode with MSVC. +
42   [small]#_[contributed by Huang Qin Jin]_#
43
44 - Ccache no longer passes `-v` to the preprocessor. This improves preprocessor
45   mode hit rate when `-v` is on the compiler command line. +
46   [small]#_[contributed by Joel Rosdahl]_#
47
48 - Made `--trim-max-size` accept 0 for no limit. +
49   [small]#_[contributed by Joel Rosdahl]_#
50
51
52 === Build improvements
53
54 - Made various fixes for Windows 64-bit MSBuild builds. +
55   [small]#_[contributed by Rafael Kitover]_#
56
57 - Silenced CMake warning for extracted timestamps. +
58   [small]#_[contributed by Rafael Kitover]_#
59
60 - Worked around problem with building ZStandard with Xcode. +
61   [small]#_[contributed by Gregor Jasny]_#
62
63 - Fixed undefined behavior (only triggered by unit tests) in
64   `util::read_file_part` for zero count, making the build fail with
65   `+_GLIBCXX_ASSERTIONS+`. +
66   [small]#_[contributed by Joel Rosdahl]_#
67
68
69 === Documentation improvements
70
71 - Clarified `--evict-older-than` semantics. +
72   [small]#_[contributed by Joel Rosdahl]_#
73
74
75 === Test improvements
76
77 - Fixed typo in "`Directory is not hashed if using -gz`" test. +
78   [small]#_[contributed by Sam James]_#
79
80
81 == Ccache 4.8.1
82
83 Release date: 2023-05-19
84
85
86 === Bug fixes
87
88 - Fixed an issue with the depend mode in combination with `--` on the command
89   line for Clang-based compilers. +
90   [small]#_[contributed by Joel Rosdahl]_#
91
92 - Improved knowledge about MSVC debug flags so that non-debug `/Z*` options are
93   once again supported. +
94   [small]#_[contributed by Stephan Rohmen]_#
95
96 - Ccache no longer treats `/Zi` as unsupported for clang-cl. +
97   [small]#_[contributed by Tobias Hieta]_#
98
99 - Made the output format of `ccache -k max_size` parsable by ccache itself. +
100   [small]#_[contributed by Joel Rosdahl]_#
101
102
103 === Build/CI improvements
104
105 - Corrected ccache version in the macOS binary release. +
106   [small]#_[contributed by Joel Rosdahl]_#
107
108 - Made it possible to build ccache with clang-cl on Windows. +
109   [small]#_[contributed by Tobias Hieta]_#
110
111 - Upgraded to doctest 2.4.11, thereby fixing a build issue on Solaris. +
112   [small]#_[contributed by Joel Rosdahl]_#
113
114
115 === Documentation improvements
116
117 - Added a remote file storage example with URL-encoded spaces. +
118   [small]#_[contributed by Joel Rosdahl]_
119
120
121 == Ccache 4.8
122
123 Release date: 2023-03-12
124
125
126 === New features and improvements
127
128 - Improved the automatic cache cleanup mechanism. Automatic cleanups are now
129   performed on 1/256 of the cache instead of 1/16, thus making them much quicker
130   (but naturally more frequent). Cleanups are coordinated between ccache
131   processes so that at most one process will perform cleanup at a time. Also,
132   the actual cache size will stay very close to the configured maximum size
133   instead of staying around 90% as was the case before. +
134   [small]#_[contributed by Joel Rosdahl]_#
135
136 - Added support for setting per-compilation configuration options on the command
137   line. Example: `ccache hash_dir=false gcc -c example.c`. +
138   [small]#_[contributed by Joel Rosdahl]_#
139
140 - Made it possible to disable ccache for a certain source code file by embedding
141   the string `ccache:disable` in a comment near the top of the file. +
142   [small]#_[contributed by Joel Rosdahl]_#
143
144 - Made ccache understand that an MSVC `/Z7` option overrides an earlier `/Z*`
145   option and thus is not too hard to cache. +
146   [small]#_[contributed by Joel Rosdahl]_#
147
148 - Added a `--recompress-threads` command line option for selecting the number of
149   CPU threads to use when recompressing the local cache. +
150   [small]#_[contributed by Joel Rosdahl]_#
151
152 - Added `--trim-recompress` and `--trim-recompress-threads` command line options
153   for recompressing file-based remote storage. +
154   [small]#_[contributed by Joel Rosdahl]_#
155
156 - Added tmpfs, ufs and zfs to the list of supported filesystems on macOS and
157   BSDs for the inode cache. +
158   [small]#_[contributed by Oleg Sidorkin]_#
159
160 - Improved progress bars for clean/clear/evict-style operations. +
161   [small]#_[contributed by Joel Rosdahl]_#
162
163 - Improved printing of cache sizes in various outputs. +
164   [small]#_[contributed by Joel Rosdahl]_#
165
166 - Activate debug logging for command mode options like `--cleanup`. +
167   [small]#_[contributed by Joel Rosdahl]_#
168
169 - Added support for `-Wp,-U<macro>` in the direct mode. +
170   [small]#_[contributed by Joel Rosdahl]_#
171
172 - Added quotes around arguments with space in logged command lines. +
173   [small]#_[contributed by Joel Rosdahl]_#
174
175 - Added logging of executed command lines on Windows. +
176   [small]#_[contributed by Joel Rosdahl]_#
177
178 - Made sure not to update the stats file when there are no incremented
179   counters. +
180   [small]#_[contributed by Joel Rosdahl]_#
181
182 - Improved actual disk size calculation on Windows. +
183   [small]#_[contributed by Joel Rosdahl]_#
184
185
186 === Build/CI improvements
187
188 - Added CI support for building macOS universal binaries. +
189   [small]#_[contributed by Raihaan Shouhell]_#
190
191 - Make it possible to force download of Zstd and Hiredis, e.g. with `cmake -D
192   ZSTD_FROM_INTERNET=ON [...]`. +
193   [small]#_[contributed by Joel Rosdahl]_#
194
195
196 === Bug fixes
197
198 - Fixed an edge case where a non-temporal identifier is misidentified. +
199   [small]#_[contributed by Erik Flodin]_#
200
201 - Fixed reporting of local/remote cache misses in depend mode. +
202   [small]#_[contributed by Joel Rosdahl]_#
203
204 - Fixed parsing of backslashes in MSVC RSP files. +
205   [small]#_[contributed by Raihaan Shouhell]_#
206
207 - Fixed a crash in `--show-log-stats` when the stats log file doesn't exist. +
208   [small]#_[contributed by Joel Rosdahl]_#
209
210 - Fixed matching of base directory for MSVC. The base directory will now match
211   case-insensitively with absolute paths in preprocessed output, or from
212   `/showIncludes` in the depend mode case, when compiling with MSVC. +
213   [small]#_[contributed by Joel Rosdahl]_#
214
215 - Fixed a problem where the original umask would be used when storing a remote
216   cache result in the local cache. +
217   [small]#_[contributed by Joel Rosdahl]_#
218
219 - Changed the inode cache implementation to use spinlocks instead of pthread
220   mutexes. This makes the inode cache work on FreeBSD and similar systems. +
221   [small]#_[contributed by Oleg Sidorkin]_#
222
223 - Don't treat `-Wp,-D` as interchangeable with `-D`. +
224   [small]#_[contributed by Joel Rosdahl]_#
225
226 - Disable the inode cache if the filesystem risks getting full soon. This fixes
227   a problem when the cache is on a filesystem where `posix_fallocate` isn't
228   reliable, like Btrfs with compression enabled. +
229   [small]#_[contributed by Joel Rosdahl]_#
230
231 - Fixed performance of cache path relativization in preprocessed output,
232   primarily on Windows where `stat` calls are relatively costly. +
233   [small]#_[contributed by Joel Rosdahl]_#
234
235 - Fixed rare crash in the signal handler at process exit. +
236   [small]#_[contributed by Joel Rosdahl]_#
237
238 - Fixed handling of Unix-style paths passed to MSVC. +
239   [small]#_[contributed by Joel Rosdahl]_#
240
241 - Fixed so that the config options and command line are logged before trying to
242   locate the compiler and exiting early. +
243   [small]#_[contributed by Joel Rosdahl]_#
244
245
246 === Documentation improvements
247
248 - Improved description of `--set-config`. +
249   [small]#_[contributed by Joel Rosdahl]_#
250
251 - Fixed broken markup in the manual. +
252   [small]#_[contributed by Joel Rosdahl]_#
253
254 - Added a note to the manual that `stats = false` will disable automatic
255   cleanup. +
256   [small]#_[contributed by Joel Rosdahl]_#
257
258 - Fix a bad reference to the "`Remote storage backends`" section. +
259   [small]#_[contributed by Joel Rosdahl]_#
260
261
262 == Ccache 4.7.5
263
264 Release date: 2023-03-20
265
266 === Bug fixes
267
268 - Disabled the inode cache by default again since there have reports of ccache
269   processes hanging on futex calls related to the inode cache. +
270   [small]#_[contributed by Joel Rosdahl]_#
271
272
273 == Ccache 4.7.4
274
275 Release date: 2022-11-21
276
277
278 === Bug fixes
279
280 - Fixed an inode cache race condition. +
281   [small]#_[contributed by Joel Rosdahl]_#
282
283 - The default temporary directory is now `$XDG_RUNTIME_DIR/ccache-tmp` instead
284   of a hardcoded `/run/user/<UID>/ccache-tmp`. If `XDG_RUNTIME_DIR` is not set,
285   `<cache_dir>/tmp` is used. This avoids creating `/run/user/<UID>` on systems
286   that don't have it if compiling as root. +
287   [small]#_[contributed by Joel Rosdahl and Oleg Sidorkin]_#
288
289 - Added a fallback in case `posix_fallocate` returns `EINVAL` when creating the
290   inode cache file. +
291   [small]#_[contributed by Oleg Sidorkin]_#
292
293 - Connection timeout for an HTTP connection is now reported as a timeout instead
294   of an error. +
295   [small]#_[contributed by Joel Rosdahl]_#
296
297 - Temporary files found in the cache are no longer counted in
298   `--show-compression`. +
299   [small]#_[contributed by Joel Rosdahl]_#
300
301 - Removed duplicate magic header in output from `--inspect`. +
302   [small]#_[contributed by Joel Rosdahl]_#
303
304 - Ccache now properly waits for all recompression jobs to finish when there is
305   no `f` subdirectory in the cache. +
306   [small]#_[contributed by Joel Rosdahl]_#
307
308
309 === Other minor improvements
310
311 - Improved inode cache logging. +
312   [small]#_[contributed by Joel Rosdahl]_#
313
314
315 === Documentation improvements
316
317 - Removed stray parenthesis. +
318   [small]#_[contributed by Joel Rosdahl]_#
319
320 - Improved description of how header files are handled. +
321   [small]#_[contributed by Joel Rosdahl]_#
322
323 - Added a hint about using `-fno-pch-timestamp` for precompiled headers with
324   Clang. +
325   [small]#_[contributed by Joel Rosdahl]_#
326
327 - Removed obsolete description of compiler type "`pump`". +
328   [small]#_[contributed by Joel Rosdahl]_#
329
330
331
332 == Ccache 4.7.3
333
334 Release date: 2022-11-05
335
336
337 === New features and improvements
338
339 - Re-added support for handling a `-Wp,-MD` or `-Wp,-MMD` option with `-o` but
340   without `-MMD`, `-MQ` or `-MT` for GCC and Clang. (This combination of options
341   is used by the Linux kernel build system and became unsupported as a
342   side-effect of a feature added in ccache 4.7.) +
343   [small]#_[contributed by Joel Rosdahl]_#
344
345 - Variables that affect Clang version on macOS are now added to the input
346   hash. +
347   [small]#_[contributed by Joel Rosdahl]_#
348
349 - Variables that affect the underlying compiler used by ICC (the Intel compiler)
350   are now added to the input hash. +
351   [small]#_[contributed by Joel Rosdahl]_#
352
353
354 === Bug fixes
355
356 - Fixed parsing of sloppiness with a trailing delimiter. +
357   [small]#_[contributed by Joel Rosdahl]_#
358
359
360 === Other minor improvements
361
362 - Removed a redundant slash in URLs when querying remote HTTP storage. +
363   [small]#_[contributed by Joel Rosdahl]_#
364
365 - Improved logging related to the inode cache. +
366   [small]#_[contributed by Joel Rosdahl]_#
367
368
369 === Documentation improvements
370
371 - Added documentation of the default value of *keep_comments_cpp*. +
372   [small]#_[contributed by Joel Rosdahl]_#
373
374
375 === Test improvements
376
377 - Silenced various benign test warnings. +
378   [small]#_[contributed by Joel Rosdahl]_#
379
380
381 == Ccache 4.7.2
382
383 Release date: 2022-10-29
384
385
386 === Bug fixes
387
388 - Fixed a problem when using 32-bit and 64-bit ccache binaries with the same
389   inode cache file. +
390   [small]#_[contributed by Joel Rosdahl]_#
391
392 - Ccache now processes the argument following a `-Xarch` option. +
393   [small]#_[contributed by an anonymous user]_#
394
395 - Made sure to use the configured umask for command line operations like
396   `--zero-stats` so that newly created cache directories will have correct
397   permissions. +
398   [small]#_[contributed by Joel Rosdahl]_#
399
400
401 === Build improvements
402
403 - Include `limits.h` for `PATH_MAX`. +
404   [small]#_[contributed by Joel Rosdahl]_#
405
406
407 === Test improvements
408
409 - Disabled flaky Windows profiling tests. +
410   [small]#_[contributed by Joel Rosdahl]_#
411
412
413 == Ccache 4.7.1
414
415 Release date: 2022-10-22
416
417
418 === Bug fixes
419
420 - Fixed a regression in 4.7 related to using the `-MD` or `-MMD` option when
421   compiling an assembler file. +
422   [small]#_[contributed by Joel Rosdahl]_#
423
424
425 === Build improvements
426
427 - Added support for compiling ccache with GCC 8. +
428   [small]#_[contributed by Orgad Shaneh]_#
429
430 - Removed unneeded C++11 flag in libatomic test. +
431   [small]#_[contributed by Orgad Shaneh]_#
432
433
434 == Ccache 4.7
435
436 Release date: 2022-10-17
437
438
439 === Compatibility notes
440
441 - The cache entry format has changed, so ccache 4.7 will not share cache entries
442   with earlier versions. Different ccache versions can however still use the
443   same cache storage without any issues.
444
445 - The https://ccache.dev/manual/4.7.html#config_cache_dir[default location of
446   the cache directory] on Windows has been changed from `%APPDATA%\ccache` to
447   `%LOCALAPPDATA%\ccache`. Please remove any existing `%APPDATA%\ccache`
448   directory or move it to `%LOCALAPPDATA%\ccache` to keep it.
449
450
451 === Changed tooling
452
453 - A C++17 compiler and CMake 3.15 or newer are now required to
454   build ccache.
455
456
457 === New and improved features
458
459 - The https://ccache.dev/manual/4.7.html#config_inode_cache[inode cache] is now
460   enabled by default, but only if the filesystem where ccache's temporary
461   directory is located is known to work with the inode cache. +
462   [small]#_[contributed by Joel Rosdahl]_#
463
464 - Improved performance of cache entry reading and writing. +
465   [small]#_[contributed by Joel Rosdahl]_#
466
467 - Added a https://ccache.dev/manual/4.7.html#config_remote_only[*remote_only*]
468   configuration option, which tells ccache to disable local storage. This way,
469   ccache can use a shared
470   link:pass:[https://ccache.dev/manual/4.7.html#_remote_storage_backends][network cache]
471   without writing cache entries locally, which can be useful if the local
472   storage is ephemeral. +
473   [small]#_[contributed by Joel Rosdahl]_#
474
475 - Renamed configuration option *secondary_storage* to
476   https://ccache.dev/manual/4.7.html#config_remote_storage[*remote_storage*].
477   The old spelling will still work as a deprecated alias. +
478   [small]#_[contributed by Joel Rosdahl]_#
479
480 - Improved handling of manifests when using both local and remote storage.
481 +
482 On a cache miss, ccache used to update the local manifest file and write it to
483 remote storage, thereby overwriting any preexisting manifest entries on remote
484 storage. Similarly, the local manifest could be replaced by the remote manifest
485 on a remote cache hit, thus discarding local entries. This has now been improved
486 so that ccache will merge local and remote manifest entries transparently. +
487 [small]#_[contributed by Joel Rosdahl and an anonymous user]_#
488
489 - Added support for caching assembler listing files with compiler option
490   `-Wa,-a=file`. This also fixes a bug in ccache 4.6.2+ where usage of
491   `-Wa,-march=...` makes ccache fall back to running the compiler. +
492   [small]#_[contributed by Joel Rosdahl]_#
493
494 - Improved statistics shown by `ccache --show-stats`. Most values are now shown
495   in relation to a total count, and some less useful statistics counters have
496   been changed to be displayed only with `--verbose`. +
497   [small]#_[contributed by Joel Rosdahl]_#
498
499 - Improved statistics for remote hits and misses. +
500   [small]#_[contributed by Joel Rosdahl]_#
501
502 - Renamed "`Primary config`" to "`Config file`" and "`Secondary config`" to
503   "`System config file`" in the output of `ccache --show-stats --verbose`. +
504   [small]#_[contributed by Joel Rosdahl]_#
505
506 - Added support for
507   link:pass:[https://ccache.dev/manual/4.7.html#_run_modes][masquerading as a
508   compiler] via a copy or hard link of the ccache executable. Previously, ccache
509   only supported masquerading as a compiler by using a symbolic link. +
510   [small]#_[contributed by Joel Rosdahl]_#
511
512 - A timestamp is now included in
513   link:pass:[https://ccache.dev/manual/4.7.html#_cache_debugging][per-object
514   debug filenames]. This makes it easier to compare two builds without having to
515   save previous debug files before the second build. It also makes sure debug
516   files won't be overwritten if an object file is compiled several times during
517   one build. +
518   [small]#_[contributed by Joel Rosdahl]_#
519
520 - Added support for Clang's `--` option. +
521   [small]#_[contributed by Joel Rosdahl]_#
522
523 - Cache entries are now shared for different `-MT`/`-MQ` options. +
524   [small]#_[contributed by Joel Rosdahl]_#
525
526 - The https://ccache.dev/manual/4.7.html#config_cache_dir[default location of
527   the cache directory] on Windows has been changed to `%LOCALAPPDATA%\ccache`,
528   both in Windows Bash and Windows native environments such as CMD or
529   Powershell.
530 +
531 Previous ccache versions defaulted to storing the cache in `%APPDATA%\ccache` on
532 Windows in native environment (i.e., when the `%USER%` variable was not set),
533 which could result in large network file transfers of the cache in domain
534 environments and similar problems. +
535 [small]#_[contributed by Rafael Kitover]_#
536
537 - Ccache now uses subsecond resolution timestamps when checking for "`too new
538   include files`". In practice, this means that the direct mode will no longer
539   be disabled for newly generated include files. +
540   [small]#_[contributed by Joel Rosdahl]_#
541
542 - Started using subsecond resolution timestamps in manifest files. This improves
543   accuracy with *file_stat_matches*
544   https://ccache.dev/manual/4.7.html#config_sloppiness[sloppiness]. +
545   [small]#_[contributed by Joel Rosdahl]_#
546
547 - Added support for subsecond timestamps on macOS. +
548   [small]#_[contributed by Joel Rosdahl]_#
549
550 - Added link:pass:[https://ccache.dev/manual/4.7.html#_the_depend_mode][depend
551   mode] support for MSVC. +
552   [small]#_[contributed by Orgad Shaneh and Luboš Luňák]_#
553
554 - Added support for the Intel compiler on Windows. +
555   [small]#_[contributed by Daniel Richtmann]_#
556
557 - Ccache now sets `CCACHE_DISABLE` when running the compiler. This avoids
558   running ccache twice (and potentially storing two different results in the
559   cache) if, for instance, the compiler happens to be a wrapper script that in
560   turn runs `ccache $compiler ...`. +
561   [small]#_[contributed by Joel Rosdahl]_#
562
563 - Added support for Redis over Unix sockets. +
564   [small]#_[contributed by Anders F Björklund]_#
565
566 - Added support for GCC's `-fprofile-abs-path` option by including the current
567   working directory in the input hash. To opt out of this, set *gcno_cwd*
568   https://ccache.dev/manual/4.7.html#config_sloppiness[sloppiness]. +
569   [small]#_[contributed by Joel Rosdahl]_#
570
571 - Made it possible to exclude `-frandom-seed=_seed_` options from the input hash
572   with a new *random_seed*
573   https://ccache.dev/manual/4.7.html#config_sloppiness[sloppiness]. +
574   [small]#_[contributed by Raihaan Shouhell]_#
575
576 - Added support for server name in
577   link:pass:[https://ccache.dev/manual/4.7.html#_file_storage_backend][remote
578   storage file URLs] on Windows. +
579   [small]#_[contributed by Joel Rosdahl]_#
580
581 - Configuration file locations are now included in the
582   link:pass:[https://ccache.dev/manual/4.7.html#_cache_debugging][debug log]. +
583   [small]#_[contributed by Joel Rosdahl]_#
584
585 - The inode cache file is no longer removed with `ccache --clear`. +
586   [small]#_[contributed by Joel Rosdahl]_#
587
588 - Result format version and number of files are now printed when inspecting a
589   result cache entry file. +
590   [small]#_[contributed by Joel Rosdahl]_#
591
592
593 === Removed features
594
595 - Removed the *share-hits* attribute for remote storage. It has been superseded
596   by the https://ccache.dev/manual/4.7.html#config_remote_only[*remote_only*]
597   configuration option. +
598   [small]#_[contributed by Joel Rosdahl]_#
599
600 - Buggy support for GCC-specific environment variables `DEPENDENCIES_OUTPUT` and
601   `SUNPRO_DEPENDENCIES` has been removed. If any of those variables are set,
602   ccache now just falls back to running the real compiler. +
603   [small]#_[contributed by Joel Rosdahl]_#
604
605
606 === Bug fixes
607
608 - The correct dependency target will now be produced even when a
609   https://ccache.dev/manual/4.7.html#config_base_dir[base directory] is used --
610   the dependency target will still be an absolute path. +
611   [small]#_[contributed by Joel Rosdahl]_#
612
613 - Fixed a bug that could lead to bad modification timestamp (mtime) for object
614   files on systems that lack `utimensat` and `utimes` system calls (such as
615   Windows). +
616   [small]#_[contributed by Joel Rosdahl]_#
617
618 - Fixed ordering of MSVC include directory options when using
619   `/external:I<directory>`. +
620   [small]#_[contributed by Raihaan Shouhell]_#
621
622 - Fixed capturing of MSVC stdout/stderr when running from Visual Studio. +
623   [small]#_[contributed by Orgad Shaneh]_#
624
625 - Carriage return characters are now retained in the compiler output on
626   Windows. +
627   [small]#_[contributed by Orgad Shaneh]_#
628
629 - Made sure not to increment the "`preprocessed_cache_miss`" counter in recache
630   mode. +
631   [small]#_[contributed by Joel Rosdahl]_#
632
633 - Fixed an issue with the inode cache in combination with
634   `+__DATE__+`/`+__TIME__+`/`+__TIMESTAMP__+` macros in the source code. +
635   [small]#_[contributed by Joel Rosdahl]_#
636
637 - Made sure to enable the inode cache only if subsecond timestamps are
638   available. +
639   [small]#_[contributed by Joel Rosdahl]_#
640
641 - Cache entries created with enabled hard linking or file cloning are no longer
642   written to remote storage since they won't be possible to retrieve correctly
643   anyway. +
644   [small]#_[contributed by Joel Rosdahl]_#
645
646 - Ccache now accepts spaces between target and colon when parsing dependency
647   files in the depend mode. +
648   [small]#_[contributed by Louis Caron]_#
649
650 - Fixed a crash when failing to write an error message to stderr after failing
651   to write to the log file. +
652   [small]#_[contributed by Joel Rosdahl]_#
653
654 - Made ccache able to retrieve an object file from the cache even if the
655   destination object file exists and is read-only. +
656   [small]#_[contributed by Joel Rosdahl]_#
657
658 - The `.exe` extension is now stripped from the ccache executable name in
659   `ccache --version` on Windows.  +
660   [small]#_[contributed by Orgad Shaneh]_#
661
662 - Fixed naming of temporary files written to the cache directory. +
663   [small]#_[contributed by Joel Rosdahl]_#
664
665
666 === Build improvements
667
668 - Enabled static runtime linking for MSVC. +
669   [small]#_[contributed by Cristian Adam and Rafael Kitover]_#
670
671 - The Zstandard and Hiredis dependencies are now by default downloaded from the
672   Internet when unavailable. +
673   [small]#_[contributed by Rafael Kitover]_#
674
675 - Added support for pkgconfig to find a Zstandard installation. +
676   [small]#_[contributed by Rosen Penev]_#
677
678 - Removed usage of the deprecated `codecvt` header. +
679   [small]#_[contributed by Orgad Shaneh]_#
680
681 - Added headers to CMake project files. +
682   [small]#_[contributed by Orgad Shaneh]_#
683
684
685 === Test improvements
686
687 - Made the integration tests work on Windows. +
688   [small]#_[contributed by Orgad Shaneh and R. Voggenauer]_#
689
690 - Improved diagnostics from the "`Version output readable`" test. +
691   [small]#_[contributed by Orgad Shaneh]_#
692
693 - Made setting the `KEEP_TESTDIR` variable actually work. +
694   [small]#_[contributed by Louis Caron]_#
695
696 - Fixed a typo in depend mode tests. +
697   [small]#_[contributed by Louis Caron]_#
698
699 - Added more depend mode tests. +
700   [small]#_[contributed by Louis Caron]_#
701
702
703 === Documentation improvements
704
705 - Improved the
706   https://github.com/ccache/ccache/blob/v4.7/doc/INSTALL.md[installation
707   guide]. +
708   [small]#_[contributed by Rafael Kitover]_#
709
710 - Fixed a typo in the help text. +
711   [small]#_[contributed by Joel Rosdahl]_#
712
713
714 == Ccache 4.6.3
715
716 Release date: 2022-08-27
717
718
719 === Bug fixes
720
721 - Fixed MSVC support (regression in ccache 4.6.2). +
722   [small]#_[contributed by Joel Rosdahl]_#
723
724 - Fixed detection of PCH header for concatenated `-include` option (e.g.,
725   `-includepch.h` instead of `-include pch.h`). +
726   [small]#_[contributed by Joel Rosdahl]_#
727
728
729 === Build improvements
730
731 - Fixed build with musl when using GCC 12. +
732   [small]#_[contributed by Khem Raj]_#
733
734
735 === Test improvements
736
737 - Disabled the "`Failure to write output file`" test when running on a
738   filesystem that doesn't support read-only directories. +
739   [small]#_[contributed by Joel Rosdahl]_#
740
741
742 == Ccache 4.6.2
743
744 Release date: 2022-08-22
745
746
747 === Bug fixes
748
749 - Fixed a race condition that could lead to a crash if a file in the cache is
750   removed with unlucky timing, e.g. by another ccache process doing cache
751   cleanup. +
752   [small]#_[contributed by Joel Rosdahl]_#
753
754 - Dependency file rewriting will now always be performed if
755   `base_dir`/`CCACHE_BASEDIR` is active. This fixes a problem with the
756   dependency file content when Clang is used with `-fsanitize=address`. +
757   [small]#_[contributed by Joel Rosdahl]_#
758
759 - Fixed handling of error condition for `--hash-file`/`--checksum-file`. +
760   [small]#_[contributed by Joel Rosdahl]_#
761
762 - Made sure to enable the inode cache only if subsecond `stat` timestamps are
763   available. +
764   [small]#_[contributed by Joel Rosdahl]_#
765
766 - Added a work-around for a Clang bug when writing to a full NFS file system. +
767   [small]#_[contributed by Joel Rosdahl]_#
768
769 - Made failure writing to the output file increment the "`bad output file`"
770   counter instead of "`cache miss`". +
771   [small]#_[contributed by Joel Rosdahl]_#
772
773 - Fixed false positive cache hits for code constructions similar to
774   `__asm__(".incbin" " \"file\"")`. +
775   [small]#_[contributed by Joel Rosdahl]_#
776
777 - Fixed false success for `-fcolor-diagnostics` probe with GCC. A side effect of
778   this is that a compiler type that ccache can't identify from the compiler name
779   (such as `/usr/bin/cc` where `cc` is not a symlink) from now on won't produce
780   color diagnostics when used via ccache even if the compiler actually is GCC or
781   Clang. +
782   [small]#_[contributed by Joel Rosdahl]_#
783
784 - More cases of invalid secondary storage URLs are now handled gracefully. +
785   [small]#_[contributed by Joel Rosdahl]_#
786
787 - Fixed the display of maximum cache size in `ccache -s` if it's 0 (=
788   unlimited). +
789   [small]#_[contributed by Joel Rosdahl]_#
790
791 - Removed AsciiDoc markup from help text of `--trim-dir`. +
792   [small]#_[contributed by Joel Rosdahl]_#
793
794 - The temporary directory is now cleaned up properly even if it's left
795   unconfigured. +
796   [small]#_[contributed by Joel Rosdahl]_#
797
798 - Made cleanup of the temporary directory not rely a directory timestamp. +
799   [small]#_[contributed by Joel Rosdahl]_#
800
801 - Made sure to retain mtime/atime when recompressing cache files with
802   `-X`/`--recompress`. +
803   [small]#_[contributed by Joel Rosdahl]_#
804
805 - The correct umask is now used when populating the primary cache from a
806   secondary cache. +
807   [small]#_[contributed by Joel Rosdahl]_#
808
809 - Fixed creation of temporary files on file systems that don't support hard
810   links (such as FAT32). +
811   [small]#_[contributed by Joel Rosdahl]_#
812
813 - Added knowledge about `-Wa,...=file` so that ccache then falls back to running
814   the real compiler. +
815   [small]#_[contributed by Joel Rosdahl]_#
816
817 - Corrected handling of space in paths when using response file on Windows. +
818   [small]#_[contributed by Sergey Semushin]_#
819
820 - Fixed crash due to empty include filename in preprocessor output generated by
821   `f2c`. +
822   [small]#_[contributed by Oleg Sidorkin]_#
823
824
825 === Build improvements
826
827 - Fixed build problems with a development version of GCC 13. +
828   [small]#_[contributed by Joel Rosdahl]_#
829
830 - Fixed build problems with MSVC. +
831   [small]#_[contributed by Florin Trofin]_#
832
833
834 === Test improvements
835
836 - Clang warnings from the "`-fdebug-prefix-map`" test are now suppressed. +
837   [small]#_[contributed by Joel Rosdahl]_#
838
839 - Made sure to only run the "`-ftest-coverage + -fprofile-dir`" test with GCC. +
840   [small]#_[contributed by Joel Rosdahl]_#
841
842 - Fixed printing of error messages with embedded newlines. +
843   [small]#_[contributed by Joel Rosdahl]_#
844
845 - Fixed warning when running the "`inode_cache`" test in isolation. +
846   [small]#_[contributed by Joel Rosdahl]_#
847
848 - Fixed test failure when the compiler used for testing is an old ccache version
849   masquerading as the compiler. +
850   [small]#_[contributed by Joel Rosdahl]_#
851
852
853 === Documentation improvements
854
855 - Mentioned that mtime is used for LRU cleanup. +
856   [small]#_[contributed by Joel Rosdahl]_#
857
858
859 == Ccache 4.6.1
860
861 Release date: 2022-05-15
862
863
864 === New features
865
866 - Added support for passing a directory to the MSVC `/Fo` option. +
867   [small]#_[contributed by Orgad Shaneh]_#
868
869 - Added knowledge about the `-imsvc` compiler option. +
870   [small]#_[contributed by Jacob Young]_#
871
872 - Added knowledge about the `-z` linker option. +
873   [small]#_[contributed by Joel Rosdahl]_#
874
875
876 === Bug fixes
877
878 - Improved handling of `.gcno` files in combination with absolute input file
879   paths. +
880   [small]#_[contributed by Joel Rosdahl]_#
881
882 - Adapted to changes in GCC 9+ `.gcno` files, which contain the current working
883   directory, by including said directory in the hash. You can opt out of this by
884   enabling "`gcno_cwd sloppiness`". +
885   [small]#_[contributed by Joel Rosdahl]_#
886
887 - A preexisting object file is no longer considered when using
888   `-fsyntax-only`. +
889   [small]#_[contributed by Joel Rosdahl]_#
890
891 - Authenticate with Redis before database selection. +
892   [small]#_[contributed by an anonymous user]_#
893
894 - Don't exit with an error on failure reading a cached file. +
895   [small]#_[contributed by an anonymous user]_#
896
897 - Bail out on too hard MSVC environment variables `CL` and `+_CL_+`. +
898   [small]#_[contributed by Joel Rosdahl]_#
899
900 - Only use `/run/user/<UID>/ccache-tmp` as the temporary directory if it's
901   writable. +
902   [small]#_[contributed by Joel Rosdahl]_#
903
904 - Fixed handling of the final newline in cached standard output from the
905   compiler. +
906   [small]#_[contributed by Orgad Shaneh]_#
907
908 - Fixed a bug related to distcc markers in standard error output. +
909   [small]#_[contributed by Joel Rosdahl]_#
910
911 - Paths to `base_dir` are now properly normalized on Windows. +
912   [small]#_[contributed by Vili Väinölä and Joel Rosdahl]_#
913
914 - Fixed handling of MSVC `/Fp` and `/Yu` options with concatenated path. +
915   [small]#_[contributed by Joel Rosdahl]_#
916
917 - Fixed "`Multiple precompiled headers used`" error if MSVC `/Yu` option is used
918   after `/Fp`. +
919   [small]#_[contributed by Alexey Telishev]_#
920
921 - Check for short reads when reading strings in result/manifest files. +
922   [small]#_[contributed by Gregor Jasny]_#
923
924 - Log expanded secondary storage URL in put/remove. +
925   [small]#_[contributed by Joel Rosdahl]_#
926
927 - Fixed logging of statistics counters with value higher than one in debug log
928   and stats log. +
929   [small]#_[contributed by Joel Rosdahl]_#
930
931 - Avoid incorrect error log message for Redis write operations in `reshare`
932   mode. +
933   [small]#_[contributed by Joel Rosdahl]_#
934
935 - Support Redis URL without host (meaning localhost). +
936   [small]#_[contributed by Joel Rosdahl]_#
937
938
939 === Build improvements
940
941 - Prefer CMake find module for hiredis and zstd packages. +
942   [small]#_[contributed by Cristian Adam and Joel Rosdahl]_#
943
944 - Fixed building and linking BLAKE3 with MSVC. +
945   [small]#_[contributed by Rafael Kitover]_#
946
947 - Fixed static linkage with hiredis on Windows. +
948   [small]#_[contributed by Orgad Shaneh]_#
949
950 - Fixed miscompile of nonstd::expected on MSVC v19.22. +
951   [small]#_[contributed by Jacob Young]_#
952
953 - Fixed build arguments to clang-cl. +
954   [small]#_[contributed by Jacob Young]_#
955
956 - Fixed parsing of MSVC response files.  +
957   [small]#_[contributed by Jacob Young]_#
958
959 - Support Git 1.x when determining ccache version. +
960   [small]#_[contributed by Joel Rosdahl]_#
961
962
963 === Test improvements
964
965 - Worked around an endianness problem which affected builds and tests on
966   big-endian systems. +
967   [small]#_[contributed by Joel Rosdahl]_#
968
969 - A C++-capable compiler is no longer required for the test suite. +
970   [small]#_[contributed by Joel Rosdahl]_#
971
972 - Fixed an issue with inode cache tests, leading to sporadic failures in the
973   inode test suite when running many parallel tests. +
974   [small]#_[contributed by Joel Rosdahl]_#
975
976 - Fixed sporadic failures in the profiling test suite. +
977   [small]#_[contributed by Jacob Young]_#
978
979
980 === Documentation improvements
981
982 - Added reference to example build configs in installation instructions. +
983   [small]#_[contributed by an anonymous user]_#
984
985 - Default cache locations are now mentioned for Windows and macOS as well. +
986   [small]#_[contributed by Joel Rosdahl]_#
987
988 - Added a warning about usage of `base_dir`. +
989   [small]#_[contributed by Joel Rosdahl]_#
990
991
992 == Ccache 4.6
993
994 Release date: 2022-02-27
995
996
997 === New features
998
999 - Added support for caching calls to Microsoft Visual C++ (MSVC) and clang-cl
1000   (MSVC compatibility for Clang). +
1001   [small]#_[contributed by Cristian Adam, Luboš Luňák, Orgad Shaneh and Joel
1002   Rosdahl]_#
1003
1004 - Added an option to use a bearer token with the HTTP backend. This makes it
1005   possible to use e.g. Google Cloud Storage as a secondary storage backend. +
1006   [small]#_[contributed by an anonymous user]_#
1007
1008 - Added support for caching standard output from the compiler. +
1009   [small]#_[contributed by Luboš Luňák and Joel Rosdahl]_#
1010
1011 - Added a new `--inspect` option for debugging cache entries, replacing the
1012   previous `--dump-manifest` and `--dump-result` options. +
1013   [small]#_[contributed by Joel Rosdahl]_#
1014
1015 - Enabled HTTP keep-alive by default. +
1016   [small]#_[contributed by Joel Rosdahl]_#
1017
1018
1019 === Bug fixes
1020
1021 - Fixed copying of binary files on Windows. +
1022   [small]#_[contributed by R. Voggenauer]_#
1023
1024 - Improved detection of the `.incbin` assembler directive to reduce false
1025   positives. +
1026   [small]#_[contributed by Alexey Sheplyakov]_#
1027
1028 - Ccache now verifies that `/run/user/<UID>/ccache-tmp` is writable before using
1029   it for temporary files. +
1030   [small]#_[contributed by Joel Rosdahl]_#
1031
1032 - Fixed statistics output for secondary storage. +
1033   [small]#_[contributed by Orgad Shaneh]_#
1034
1035 - Fixed a problem when copying a cache entry from secondary storage into an
1036   empty primary storage. +
1037   [small]#_[contributed by Joel Rosdahl]_#
1038
1039 - Visual Studio .rsp files with UTF-16LE encoding are now handled correctly. +
1040   [small]#_[contributed by Vili Väinölä]_#
1041
1042 - Made conversion to relative paths more reliable on Windows. +
1043   [small]#_[contributed by Marius Zwicker]_#
1044
1045 - The process umask is now respected when making hard linked files read only. +
1046   [small]#_[contributed by Joel Rosdahl]_#
1047
1048 - A forced recache is no longer considered a "`direct cache miss`". +
1049   [small]#_[contributed by Joel Rosdahl]_#
1050
1051
1052 === Documentation improvements
1053
1054 - Corrected reference to the `debug_dir` option. +
1055   [small]#_[contributed by Joel Rosdahl]_#
1056
1057 - Improved documentation of `--config-path`. +
1058   [small]#_[contributed by Joel Rosdahl]_#
1059
1060 - Added documentation that compiler plugins are hashed too. +
1061   [small]#_[contributed by Philipp Gortan]_#
1062
1063
1064 === Test improvements
1065
1066 - The "`trim_dir`" test suite is now only run when cleanup tests are enabled. +
1067   [small]#_[contributed by Joel Rosdahl]_#
1068
1069
1070 == Ccache 4.5.1
1071
1072 Release date: 2021-11-17
1073
1074
1075 === Bug fixes
1076
1077 - Fixed entry_size field for result entries. This bug affected the recompression
1078   feature (`-X`/`--recompress`) in ccache 4.5. +
1079   [small]#_[contributed by Joel Rosdahl]_#
1080
1081 - The actual compression level is now once again stored in the cache entry
1082   header. +
1083   [small]#_[contributed by Joel Rosdahl]_#
1084
1085 - Corrected error handling for non-constructible secondary storage backends. For
1086   instance, this avoids a crash when a Redis server can't be reached. +
1087   [small]#_[contributed by Joel Rosdahl]_#
1088
1089
1090 == Ccache 4.5
1091
1092 Release date: 2021-11-13
1093
1094
1095 === New features
1096
1097 - Made various improvements to the cache entry format. Among other things, the
1098   header now contains a creation timestamp and a note of the ccache version used
1099   to create the entry. The cache entry checksum has also been upgraded to use
1100   128-bit XXH3 instead 64-bit XXH3. +
1101   [small]#_[contributed by Joel Rosdahl]_#
1102
1103 - Added support for cache namespaces. If a namespace configured, e.g. using
1104   `CCACHE_NAMESPACE=some_string`, the namespace string will be added to the
1105   hashed data for each compilation. This will make the associated cache entries
1106   logically separate from cache entries in other namespaces, but they will still
1107   share the same storage space. Cache entries can also be selectively removed
1108   from the primary cache with the new command line option `--evict-namespace`,
1109   potentially in combination with `--evict-older-than`. +
1110   [small]#_[contributed by Joel Rosdahl]_#
1111
1112 - Made HTTP keep-alive configurable, defaulting to off for now. +
1113   [small]#_[contributed by Gregor Jasny]_#
1114
1115 - Added support for rewriting absolute path to Clang option `--gcc-toolchain`. +
1116   [small]#_[contributed by Joel Rosdahl]_#
1117
1118
1119 === Compatibility notes
1120
1121 - A consequence of the changed cache entry format is that ccache 4.5 will not
1122   share cache entries with earlier versions. Different ccache versions can
1123   however still use the same cache storage without any issues.
1124
1125
1126 === Bug fixes
1127
1128 - Fixed a problem with special characters in the user info part of URLs for HTTP
1129   storage. +
1130   [small]#_[contributed by Russell McClellan]_#
1131
1132 - Fixed win32 log messages about file locks. +
1133   [small]#_[contributed by Luboš Luňák]_#
1134
1135 - Fixed debug directory handling on Windows. +
1136   [small]#_[contributed by Luboš Luňák]_#
1137
1138 - The hard link and file clone features are now disabled when secondary storage
1139   is used since they only work for the local primary cache. +
1140   [small]#_[contributed by Joel Rosdahl]_#
1141
1142
1143 == Ccache 4.4.2
1144
1145 Release date: 2021-09-28
1146
1147
1148 === Bug fixes
1149
1150 - Fixed a bug introduced in 4.4 where ccache could produce false direct cache
1151   hits in some situations if it decides to disable the direct mode temporarily
1152   (e.g. due to "`too new header`" file). +
1153   [small]#_[contributed by Joel Rosdahl]_#
1154
1155
1156 === Test improvements
1157
1158 - Use shell builtin pwd command for basedir test. +
1159   [small]#_[contributed by Kira Bruneau]_#
1160
1161 - Cope with CC being a wrapper script that uses ccache. +
1162   [small]#_[contributed by Joel Rosdahl]_#
1163
1164
1165 == Ccache 4.4.1
1166
1167 Release date: 2021-09-11
1168
1169
1170 === New features
1171
1172 - The secondary storage statistics section of `-s/--show-stats` is now shown
1173   only if it's non-empty or with two verbose options. +
1174   [small]#_[contributed by Joel Rosdahl]_#
1175
1176 - Added display of statistics counters for misses. Previously they were only
1177   implicit in the "`hits + misses`" sums. +
1178   [small]#_[contributed by Joel Rosdahl]_#
1179
1180
1181 === Bug fixes
1182
1183 - Fixed spurious crashes when using the HTTP or Redis backend and the remote
1184   connection hung up. +
1185   [small]#_[contributed by Joel Rosdahl]_#
1186
1187 - Made sure to always store configuration origin value. +
1188   [small]#_[contributed by Gregor Jasny]_#
1189
1190
1191 === Build improvements
1192
1193 - The matching version of lld is now used for Clang. +
1194   [small]#_[contributed by Gregor Jasny]_#
1195
1196 - The standard linker is now used if IPO (LTO) is enabled. +
1197   [small]#_[contributed by Gregor Jasny]_#
1198
1199 - Disabled IPO (LTO) for MinGW toolchains since they seem to be generally
1200   broken. +
1201   [small]#_[contributed by Gregor Jasny]_#
1202
1203 - Fixed build errors with Clang on Windows. +
1204   [small]#_[contributed by Orgad Shaneh]_#
1205
1206
1207 === Test improvements
1208
1209 - Fixed .incbin test with newer binutil versions. +
1210   [small]#_[contributed by Joel Rosdahl]_#
1211
1212 - Fixed basedir test suite failure when using a symlinked CWD. +
1213   [small]#_[contributed by Joel Rosdahl]_#
1214
1215 - Improved output of differing text files on failure. +
1216   [small]#_[contributed by Joel Rosdahl]_#
1217
1218
1219 == Ccache 4.4
1220
1221 Release date: 2021-08-19
1222
1223
1224 === New features
1225
1226 - Made it possible to share a cache over network or on a local filesystem. The
1227   configuration option `secondary_storage`/`CCACHE_SECONDARY_STORAGE` specifies
1228   one or several storage backends to query after the primary local cache
1229   storage. It is also possible to configure sharding (partitioning) of the cache
1230   to spread it over a server cluster using
1231   https://en.wikipedia.org/wiki/Rendezvous_hashing[Rendezvous hashing]. See the
1232   _https://ccache.dev/manual/4.4.html#_secondary_storage_backends[Secondary
1233   storage backends]_ chapter in the manual for details. +
1234   [small]#_[contributed by Joel Rosdahl]_#
1235
1236 - Added an HTTP backend for secondary storage on any HTTP server that supports
1237   GET/PUT/DELETE methods. See https://ccache.dev/howto/http-storage.html[How to
1238   set up HTTP storage] for hints on how to set up an HTTP server for use with
1239   ccache. +
1240   [small]#_[contributed by Gregor Jasny]_#
1241
1242 - Added a Redis backend for secondary storage on any server that supports the
1243   Redis protocol. See https://ccache.dev/howto/redis-storage.html[How to set up
1244   Redis storage] for hints on how to set up a Redis server for use with
1245   ccache. +
1246   [small]#_[contributed by Anders F Björklund]_#
1247
1248 - Added a filesystem backend for secondary storage. It can for instance be used
1249   for a shared cache over networked filesystems such as NFS, or for mounting a
1250   secondary read-only cache layer into a build container. +
1251   [small]#_[contributed by Joel Rosdahl]_#
1252
1253 - Added `--trim-dir`, `--trim-max-size` and `--trim-method` options that can be
1254   used to trim a secondary storage directory to a certain size, e.g. via
1255   cron. +
1256   [small]#_[contributed by Joel Rosdahl]_#
1257
1258 - Added a configuration option `reshare`/`CCACHE_RESHARE` which makes ccache
1259   send results to secondary storage even for primary storage cache hits. +
1260   [small]#_[contributed by Joel Rosdahl]_#
1261
1262 - Added new statistics counters for direct/preprocessed cache misses, primary
1263   storage hits/misses, secondary storage hits/misses/errors/timeouts and forced
1264   recaches. +
1265   [small]#_[contributed by Joel Rosdahl]_#
1266
1267 - Improved statistics summary. The `-s`/`--show-stats` option now prints a more
1268   condensed overview where the counters representing "`uncacheable calls`" are
1269   summed as uncacheable and errors counters. The summary shows hit rate for
1270   direct/preprocessed hits/misses, as well as primary/secondary storage
1271   hits/misses. More details are shown with `-v`/`--verbose`. Note: Scripts
1272   should use `--print-stats` (available since ccache 3.7) instead of trying to
1273   parse the output of `--show-stats`. +
1274   [small]#_[contributed by Joel Rosdahl]_#
1275
1276 - Added a "`stats log`" feature (configuration option
1277   `stats_log`/`CCACHE_STATSLOG`), which tells ccache to store statistics in a
1278   separate log file specified by the user. It can for instance be used to
1279   collect statistics for a single build without interference from other
1280   concurrent builds. Statistics from the log file can then be viewed with
1281   `ccache --show-log-stats`. +
1282   [small]#_[contributed by Anders F Björklund]_#
1283
1284 - Added support for clang's `--config` option. +
1285   [small]#_[contributed by Tom Stellard]_#
1286
1287 - Added support for one `-Xarch_*` option that matches a corresponding `-arch`
1288   option. +
1289   [small]#_[contributed by Joel Rosdahl]_#
1290
1291 - Renamed the `--directory` option to `--dir` for consistency with other
1292   options. +
1293   [small]#_[contributed by Joel Rosdahl]_#
1294
1295 - Made the `--config-path` and `--dir` options affect the whole command line so
1296   that they don't have to be put before `-s`/`--show-stats`. +
1297   [small]#_[contributed by Joel Rosdahl]_#
1298
1299 - Made `--dump-manifest` and `--dump-result` accept filename `-` for reading
1300   from standard input. +
1301   [small]#_[contributed by Anders F Björklund]_#
1302
1303 - Made the output of `--print-stats` sorted. +
1304   [small]#_[contributed by Joel Rosdahl]_#
1305
1306 - Added more internal trace points. +
1307   [small]#_[contributed by Joel Rosdahl]_#
1308
1309
1310 === Bug fixes
1311
1312 - Fixed a crash if using `base_dir` and `$PWD` is set to a relative path. +
1313   [small]#_[contributed by Joel Rosdahl]_#
1314
1315 - Fixed a bug with `-fprofile-generate` where ccache could give false positive
1316   cache hits when compiling with relative paths in another directory. +
1317   [small]#_[contributed by Joel Rosdahl]_#
1318
1319 - Fixed a bug in `debug_dir`/`CCACHE_DEBUGDIR`. The absolute path to the object
1320   file was not created correctly if the object file didn't already exist. +
1321   [small]#_[contributed by Joel Rosdahl]_#
1322
1323 - Disabled preprocessor hits for pre-compiled headers with Clang again. +
1324   [small]#_[contributed by Arne Hasselbring]_#
1325
1326 - Fixed a problem when using the Gold linker on MIPS by only probing for a
1327   faster linker in dev build mode and on x86_64. +
1328   [small]#_[contributed by Joel Rosdahl]_#
1329
1330 - Made the `-DENABLE_TRACING=1` mode work again. +
1331   [small]#_[contributed by Anders F Björklund]_#
1332
1333
1334 === Changed tooling
1335
1336 - A C++14 compiler or newer is now required to build ccache. For GCC, this means
1337   version 6 or newer in practice.
1338
1339 - CMake 3.10 or newer is now required to build ccache.
1340
1341 - https://asciidoctor.org[Asciidoctor] is now required to build ccache
1342   documentation.
1343
1344
1345 === Build/test/documentation improvements
1346
1347 - Fixed an issue in the modules test suite that showed up when running the
1348   ccache test suite with the clang wrapper provided by Nixpkgs. +
1349   [small]#_[contributed by Ryan Burns]_#
1350
1351 - Made the nvcc_ldir test suite require a working NVCC. +
1352   [small]#_[contributed by Michael Kruse]_#
1353
1354 - Made the ivfsoverlay test suite more robust. +
1355   [small]#_[contributed by Michael Kruse]_#
1356
1357 - Fixed issue with usage of `/FI` when building ccache with MSVC. +
1358   [small]#_[contributed by Michael Kruse]_#
1359
1360 - Fixed Apple Clang detection in the integration test suite. +
1361   [small]#_[contributed by Gregor Jasny]_#
1362
1363 - Made clang the default compiler when running the test suite on macOS. +
1364   [small]#_[contributed by Gregor Jasny]_#
1365
1366 - Silenced stray printout from "-P -c" test case. +
1367   [small]#_[contributed by Joel Rosdahl]_#
1368
1369 - Fixed selection of the ccache binary to use when running the test suite with
1370   multi-config generators like Xcode. +
1371   [small]#_[contributed by Gregor Jasny]_#
1372
1373 - Fixed CMake feature detection for `ctim`/`mtim` fields in `struct stat`. +
1374   [small]#_[contributed by Gregor Jasny]_#
1375
1376 - Fixed issue with not linking to .lib correctly on Windows. +
1377   [small]#_[contributed by R. Voggenauer]_#
1378
1379 - Made it possible to override `CCACHE_DEV_MODE` on the command line. +
1380   [small]#_[contributed by Joel Rosdahl]_#
1381
1382 - Improved HTML documentation style. +
1383   [small]#_[contributed by Joel Rosdahl with minor fixes by Orgad Shaneh]_#
1384
1385
1386 == Ccache 4.3
1387
1388 Release date: 2021-05-09
1389
1390
1391 === New features
1392
1393 - Ccache now ignores the Clang compiler option `-ivfsoverlay` and its argument
1394   if you opt in to "`ivfsoverlay sloppiness`". This is useful if you use Xcode,
1395   which uses a virtual file system (VFS) for things like combining Objective-C
1396   and Swift code.
1397
1398 - When using `-P` in combination with `-E`, ccache now reports this as "`called
1399   for preprocessing`" instead of "`unsupported compiler option`".
1400
1401 - Added support for `-specs file.specs` and `--specs file.specs` without an
1402   equal sign between the arguments.
1403
1404
1405 === Bug fixes
1406
1407 - "`Split dwarf`" code paths are now disabled when outputting to `/dev/null`. This
1408   avoids an attempt to delete `/dev/null.dwo`.
1409
1410 - Made the `stat`/`lstat` wrapper function for Windows treat pending deletes as
1411   missing files.
1412
1413 - Fixed a bug that made ccache process header files redundantly for some
1414   relative headers when using Clang.
1415
1416 - The object path is now included in the input hash when using `-fprofile-arcs`
1417   (or `--coverage`) since the object file embeds a `.gcda` path based on the
1418   object file path.
1419
1420
1421 === Build improvements
1422
1423 - Added an `ENABLE_DOCUMENTATION` build option (default: true) that can be used
1424   to disable the build of documentation.
1425
1426 - Fixed detection of pthread features.
1427
1428 - Quote CMake variables expansions to avoid errors when
1429   `${CMAKE_C_FLAGS_RELWITHDEBINFO}` or `${CMAKE_CXX_FLAGS_RELWITHDEBINFO}`
1430   expands to the empty string.
1431
1432
1433 == Ccache 4.2.1
1434
1435 Release date: 2021-03-27
1436
1437
1438 === Bug fixes
1439
1440 - Ccache now only duplicates the stderr file descriptor into `$UNCACHED_ERR_FD`
1441   for calls to the preprocessor/compiler. This works around a complex bug in
1442   interaction with GNU Make, LTO linking and the Linux PTY driver.
1443
1444 - Fixed detection of color diagnostics usage when using `-Xclang
1445   -fcolor-diagnostics` options.
1446
1447 - The `-frecord-gcc-switches` compiler option is now handled correctly to avoid
1448   false positive cache hits.
1449
1450 - Made it possible for per-compilation debug log files to be written in most
1451   argument processing error scenarios. Previously, ccache would only write debug
1452   log files if the argument processing phase was successful.
1453
1454 - Made ccache bail out on too hard Clang option `-gen-cdb-fragment-path`.
1455
1456 - The `run_second_cpp` made is now enforced on macOS if `-g` is used since newer
1457   Clang versions on macOS produce different debug information when compiling
1458   preprocessed code.
1459
1460 - Made ccache only reject `-f(no-)color-diagnostics` for a known GCC compiler.
1461   This fixes a problem when using said option with Clang on macOS.
1462
1463 - Implemented a better `stat`/`lstat` wrapper function for Windows.
1464
1465 - Fixed a bug where ccache could return stale cache results on Windows.
1466
1467 - Fixed handling of long command lines on Windows.
1468
1469
1470 === Portability and build improvements
1471
1472 - Build configuration scripts now probe for atomic increment as well. This fixes
1473   a linking error on Sparc.
1474
1475 - An existing CMake log message level is now used when warning about not finding
1476   asciidoc.
1477
1478 - Added support for building ccache with xlclang++ on AIX 7.2.
1479
1480 - Fixed assertion in the "`Debug option`" test.
1481
1482 - Made build configuration skip using ccache when building with MSVC.
1483
1484 - Upgraded to doctest 2.4.6. This fixes a build error with glibc >= 2.34.
1485
1486
1487 === Documentation
1488
1489 - Fixed markup of `compiler_type` value `other`.
1490
1491 - Fixed markup of `debug_dir` documentation.
1492
1493 - Fixed references to the `extra_files_to_hash` configuration option.
1494
1495
1496 == Ccache 4.2
1497
1498 Release date: 2021-02-02
1499
1500
1501 === New features
1502
1503 - Improved calculation of relative paths when using `base_dir` to also consider
1504   canonical paths (i.e. paths with dereferenced symlinks) as candidates.
1505
1506 - Added a `debug_dir` (`CCACHE_DEBUGDIR`) configuration setting for specifying a
1507   directory for files written in debug mode.
1508
1509 - Added support for compiler option `-x cuda`, understood by Clang.
1510
1511 - The value of the `SOURCE_DATE_EPOCH` variable is now only hashed if it
1512   potentially affects the output from ccache. This means that ccache now (like
1513   before version 4.0) will be able to produce cache hits for source code that
1514   doesn't contain `+__DATE__+` or `+__TIME__+` macros regardless of the value of
1515   `SOURCE_DATE_EPOCH`.
1516
1517
1518 === Bug fixes
1519
1520 - Fixed a bug where a non-Clang compiler would silently accept the
1521   Clang-specific `-f(no-)color-diagnostics` option when run via ccache. This
1522   confused feature detection made by e.g. CMake.
1523
1524 - Improved creation of temporary files on Windows. Previously, ccache would in
1525   practice reuse temporary filenames on said platform resulting in various
1526   problems with parallel builds.
1527
1528 - Fixed creation of parent directories when creating a lock file on Windows.
1529
1530 - Fixed a race condition related to removal of temporary files.
1531
1532 - Improved calculation of directory name for a Windows-style path.
1533
1534 - A compilation result is now not stored in the cache if an included
1535   preprocessed header file is too new. This fixes a bug where the content of a
1536   newly created preprocessed header file could be missing from the hash,
1537   resulting in a false positive cache hit.
1538
1539 - Fixed calculation of the split DWARF filename for an object filename with zero
1540   or multiple dots.
1541
1542 - Fixed retrieval of the object file the destination is `/dev/null`.
1543
1544
1545 === Portability and build improvements
1546
1547 - Additional compiler flags like `-Wextra -Werror` are now only added when
1548   building ccache in developer mode.
1549
1550 - The developer build mode no longer enables `-Weverything` for Clang.
1551
1552 - `_XOPEN_SOURCE` is now defined appropriately on FreeBSD to fix missing
1553   declaration of `isascii`.
1554
1555 - Improved detection of buildability of BLAKE3 assembler files.
1556
1557 - Disabled build of inode cache code on OSes without
1558   `pthread_mutexattr_setpshared`, such as OpenBSD.
1559
1560 - Made static linking the default for a Windows MinGW build.
1561
1562 - Removed legacy fallback replacements of `mkstemp` and `realpath`.
1563
1564 - Improved detection of SSE/AVX support.
1565
1566 - Improved detection of support for the AVX2 target attribute.
1567
1568 - Configuration scripts now try to detect and enable BLAKE3's Neon support.
1569
1570 - Made it possible to run the integration test suite on macOS.
1571
1572 - Fixed building of 32-bit unit tests on macOS.
1573
1574 - Made it possible to compile ccache for C++17.
1575
1576 - Fixed printing of 64-bit `time_t` on 32-bit architectures like RISCV32.
1577
1578 - Made sure to only use ASCII characters in the manual's AsciiDoc source code to
1579   make it possible to generate documentation in non-UTF8 locales.
1580
1581 - Upgraded to optional-lite 3.4.0, fmt 7.1.3, doctest 2.4.4 and zstd 1.4.8.
1582
1583 - Took steps towards being able to run the test suite on Windows.
1584
1585
1586 === Documentation
1587
1588 - Improved wording of `compiler_check` string values.
1589
1590 - Improved documentation of compression levels and the `-X/--recompress` option.
1591
1592 - Improved consistency of terms in the manual.
1593
1594 - HTML documentation is now built and installed by default if possible.
1595
1596 - Fixed incorrect documentation of configuration option `cache_dir`.
1597
1598 - Added hint on how to link statically with libzstd.
1599
1600 - Mention that ccache requires the `-c` compiler option.
1601
1602
1603 == Ccache 4.1
1604
1605 Release date: 2020-11-22
1606
1607
1608 === New features
1609
1610 - Symlinks are now followed when guessing the compiler. This makes ccache able
1611   to guess compiler type "`GCC`" for a common symlink chain like this:
1612   `/usr/bin/cc` -> `/etc/alternatives/cc` -> `/usr/bin/gcc` -> `gcc-9` ->
1613   `x86_64-linux-gnu-gcc-9`.
1614
1615 - Added a new `compiler_type` (`CCACHE_COMPILERTYPE`) configuration option that
1616   allows for overriding the guessed compiler type.
1617
1618 - Added support for caching compilations with `-fsyntax-only`.
1619
1620 - Added a command line option `--config-path`, which specifies the
1621   configuration file to operate on. It can be used instead of setting
1622   `CCACHE_CONFIGPATH` temporarily.
1623
1624
1625 === Bug fixes
1626
1627 - The original color diagnostics options are now retained when forcing colored
1628   output. This fixes a bug where feature detection of the `-fcolor-diagnostics`
1629   option would succeed when run via ccache even though the actual compiler
1630   doesn't support it (e.g. GCC <4.9).
1631
1632 - Fixed a bug related to umask when using the `umask` (`CCACHE_UMASK`)
1633   configuration option.
1634
1635 - Allow `ccache ccache compiler ...` (repeated `ccache`) again.
1636
1637 - Fixed parsing of dependency file in the "`depend mode`" so that filenames with
1638   space or other special characters are handled correctly.
1639
1640 - Fixed rewriting of the dependency file content when the object filename
1641   includes space or other special characters.
1642
1643 - Fixed runtime detection of AVX2 support, not relying on the sometimes broken
1644   `__builtin_cpu_support` routine.
1645
1646 - Added missing parameters to a log call, thus avoiding a crash when it is
1647   found out at runtime that file cloning is unsupported by the OS.
1648
1649
1650 === Portability and build fixes
1651
1652 - The ccache binary is now linked with `libatomic` if needed. This fixes build
1653   problems with GCC on ARM and PowerPC.
1654
1655 - Fixed build of BLAKE3 code with Clang 3.4 and 3.5.
1656
1657 - Fixed "`use of undeclared identifier 'CLONE_NOOWNERCOPY'`" build error on
1658   macOS 10.12.
1659
1660 - Fixed build problems related to missing AVX2 and AVX512 support on older
1661   macOS versions.
1662
1663 - Fixed static linkage with libgcc and libstdc++ for MinGW and made it
1664   optional.
1665
1666 - Fixed conditional compilation of "`robust mutex`" code for the inode cache
1667   routines.
1668
1669 - Fixed badly named man page filename (`Ccache.1` instead of `ccache.1`).
1670
1671 - Disabled some tests on ancient Clang versions.
1672
1673
1674 === Other improvements and fixes
1675
1676 - The man page is now built by default if the required tools are available.
1677
1678 - Use CMake `A2X_EXE` variable instead of hardcoded `a2x`.
1679
1680 - Improved build errors when building ccache with very old compiler versions.
1681
1682 - Fall back to version "`unknown`" when Git is not installed.
1683
1684 - Documented the relationship between `CCACHE_DIR` and `-d/--directory`.
1685
1686 - Fixed incorrect reference and bad markup in the manual.
1687
1688
1689 == Ccache 4.0
1690
1691 Release date: 2020-10-18
1692
1693
1694 === Summary of major changes
1695
1696 - Changed the default cache directory location to follow the XDG base directory
1697   specification.
1698
1699 - Changed compression algorithm from Deflate (zlib) to Zstandard, enabled by
1700   default.
1701
1702 - Added functionality for recompressing cache content with a higher compression
1703   level.
1704
1705 - Changed hash algorithm from MD4 to BLAKE3.
1706
1707 - Added checksumming with XXH3 to detect data corruption.
1708
1709 - Improved cache directory structure.
1710
1711 - Added support for using file cloning (AKA "`reflinks`").
1712
1713 - Added an experimental "`inode cache`" for file hashes.
1714
1715
1716 === Compatibility notes
1717
1718 - The default location of the cache directory has changed to follow the XDG
1719   base directory specification (<<Detailed functional changes,more details
1720   below>>). This means that scripts can no longer assume that the cache
1721   directory is `~/.ccache` by default. The `CCACHE_DIR` environment variable
1722   still overrides the default location just like before.
1723
1724 - The cache directory structure has changed compared to previous versions
1725   (<<Detailed functional changes,more details below>>). This means that ccache
1726   4.0 will not share cache results with earlier versions. It is however safe to
1727   run ccache 4.0 and earlier versions against the same cache directory: cache
1728   bookkeeping, statistics and cleanup are backward compatible, with the minor
1729   exception that some statistics counters incremented by ccache 4.0 won't be
1730   visible when running `ccache -s` with an older version.
1731
1732
1733 === Changed tooling
1734
1735 - CMake is now used instead of Autoconf for configuration and building.
1736
1737 - A C++11 compiler, a C99 compiler and CMake 3.4.3 or newer are now required to
1738   build ccache.
1739
1740 - Ccache can now be built using Microsoft Visual C++.
1741
1742
1743 === Detailed functional changes
1744
1745 - All data of a cached result is now stored in a single file called "`result`"
1746   instead of up to seven files. This reduces inode usage and improves data
1747   locality.
1748
1749 - Added compression of result and manifest files using the
1750   http://zstd.net[Zstandard] algorithm. Compression is enabled by default with
1751   compression level 1. This makes ccache able to store more data in the cache.
1752   Previously compression using Deflate (zlib) was available but disabled by
1753   default. Files can be recompressed with another compression level later with
1754   the `-X/--recompress` option described further below.
1755
1756 - Changed from MD4 to https://blake3.io[BLAKE3] for hashing input. This
1757   improves performance and reduces the risk of hash collisions.
1758
1759 - Added checksumming of result and manifest files using the
1760   http://xxhash.com[XXH3] algorithm to detect data corruption.
1761
1762 - Ccache now follows the
1763   https://specifications.freedesktop.org/basedir-spec/[XDG base directory
1764   specification]. This means that the default cache directory on Unix systems
1765   is `$XDG_CACHE_HOME/ccache` (with `~/.cache/ccache` as the fallback if
1766   `XDG_CACHE_HOME` is not set) and the configuration file is
1767   `$XDG_CONFIG_HOME/ccache/ccache.conf` (with `~/.config/ccache/ccache.conf` as
1768   the fallback). On macOS, the fallbacks are `~/Library/Caches/ccache` and
1769   `~/Library/Preferences/ccache/ccache.conf`. On Windows, the fallbacks are
1770   `%APPDATA%/ccache` and `%APPDATA%/ccache/ccache.conf`. Exception: If the
1771   legacy `~/.ccache` directory exists, that directory is used as the default
1772   cache location and the configuration file is `~/.ccache/ccache.conf`.
1773
1774 - Cache statistics are now stored in files on cache level 2 to reduce lock
1775   contention when there are many parallel compilations.
1776
1777 - An appropriate cache directory level structure is now chosen automatically.
1778   The `cache_dir_levels` (`CCACHE_NLEVELS`) configuration option has therefore
1779   been removed.
1780
1781 - Added an experimental "`inode cache`" for file hashes, allowing computed hash
1782   values to be reused both within and between builds. The inode cache is off by
1783   default but can be enabled by setting `inode_cache` (`CCACHE_INODECACHE`) to
1784   `true`.
1785
1786 - Added support for using file cloning (AKA "`reflinks`") on Btrfs, XFS and APFS
1787   to copy data to and from the cache very efficiently.
1788
1789 - Two measures have been implemented to make the hard link mode safer:
1790   hard-linked files are made read-only and inadvertent content changes that
1791   affect file size are detected.
1792
1793 - Added a command line option `-x/--show-compression` which shows statistics
1794   about cache compression.
1795
1796 - Added a command line option `-X/--recompress` which recompresses the cache
1797   data with another compression level or makes it uncompressed. If you choose
1798   to disable compression by default, or choose to use a compression level with
1799   a low compression ratio, you can recompress the cache with a higher
1800   compression level after the build or at another time when there are more CPU
1801   cycles available, for instance every night. Only files that are currently
1802   compressed with a different level than the wanted level will be recompressed.
1803
1804 - Added a command line option `--evict-older-than` which removes cache entries
1805   older than a certain age.
1806
1807 - Added a command line option `-d/--directory` which specifies a cache
1808   directory to operate on. It can be used instead of setting `CCACHE_DIR`
1809   temporarily.
1810
1811 - A progress bar has been added to show the progress of time-consuming options
1812   like `-c/--cleanup`, `-C/--clear`, `--evict-older-than`,
1813   `-x/--show-compression` and `-X/--recompress`.
1814
1815 - When supported by the CPU, a SIMD-friendly (using AVX2) algorithm is now used
1816   to scan input source code for `+__DATE__+`, `+__TIME__+` and `+__TIMESTAMP__+`
1817   macros. This can decrease the number of CPU cycles for a direct cache hit with
1818   up to 15% in some cases.
1819
1820 - Some unnecessary `stat(2)` system calls are now avoided when verifying header
1821   files.
1822
1823 - Compiler diagnostic messages are now always cached in color. Ccache then
1824   strips the color codes on the fly when requested explicitly by a command line
1825   option or when stderr does not refer to a TTY. This allows IDEs and terminals
1826   to share cached compilation results.
1827
1828 - The configuration option `compiler` (`CCACHE_COMPILER`) now always takes
1829   effect if specified. Previously, the configuration option was only used when
1830   the compiler specified on the command line was looked up via `PATH` (i.e.,
1831   not when an absolute path was specified).
1832
1833 - Added optional logging to syslog if `log_file` (`CCACHE_LOGFILE`) is set to
1834   `syslog`.
1835
1836 - The compiler option `-fmodules` is now handled in the "`depend mode`". If
1837   "`depend mode`" is disabled the option is still considered too hard and ccache
1838   will fall back to running the compiler.
1839
1840 - Ccache can now cache compilations with coverage notes (`.gcno` files)
1841   produced by GCC 9+ in combination with `-fprofile-dir=dir`.
1842
1843 - `realpath(3)` is no longer used for normalization when computing relative
1844   paths. This makes it possible to get cache hits when the source or build
1845   directory is a symbolic link to an absolute path that includes unstable
1846   information like build IDs or timestamps.
1847
1848 - Added an `ignore_options` (`CCACHE_IGNOREOPTIONS`) configuration option which
1849   makes it possible to exclude compiler options from the hash.
1850
1851 - Added an `absolute_paths_in_stderr` (`CCACHE_ABSSTDERR`) configuration option
1852   which makes ccache rewrite absolute paths in compiler warnings and errors to
1853   relative.
1854
1855 - Improved handling of umask. The configured `umask` (`CCACHE_UMASK`) is now
1856   only applied to files and directories in the cache directory. Previously the
1857   umask was applied to all files produced by ccache and the executed compiler.
1858
1859 - Ccache is now able to share cache entries for different object file names
1860   when using `-MD` or `-MMD`.
1861
1862 - Clang's `-Xclang` (used by CMake for precompiled headers),
1863   `-fno-pch-timestamp`, `-emit-pch`, `-emit-pth` and `-include-pth` options are
1864   now understood.
1865
1866 - Added support for the HIP ("`C++ Heterogeneous-Compute Interface for
1867   Portability`") language.
1868
1869 - The manifest format now allows for header files larger than 4 GiB.
1870
1871 - Made it possible to once again cache compilations with `+__DATE__+` in the
1872   source code.
1873
1874 - Added handling of the `+__TIMESTAMP__+` macro.
1875
1876 - An absolute input source path is now rewritten to a relative path when using
1877   `base_dir`.
1878
1879 - `waitpid` system calls interrupted by a signal are now handled correctly.
1880
1881 - Made handling of `.dwo` files and interaction between `-gsplit-dwarf` and
1882   other `-g*` options more robust.
1883
1884 - The "`couldn't find compiler`" statistics counter is no longer incremented
1885   when ccache exits with a fatal error.
1886
1887 - Failure to run a `compiler_check` command is no longer a fatal error.
1888
1889 - Added command line options `--dump-result` and `--extract-result` for
1890   inspecting and extracting result files.
1891
1892 - Added a command line option `--checksum-file` for debugging or evaluating the
1893   checksum algorithm.
1894
1895 - Improved error message for `ccache -o=K=V` (trying to set a configuration
1896   option named `=K`).
1897
1898 - Made timestamps in statistics files Y2038-proof.
1899
1900 - Removed code for populating a newly created configuration file with max cache
1901   size and max files values for cache directories created by ccache versions
1902   older than 3.2 (released 2014).
1903
1904 - Removed knowledge about a top-level `stats` file created by ccache versions
1905   older than 3.1 (released 2010).
1906
1907
1908 === Other improvements
1909
1910 - Improved help text and documentation of command line options.
1911
1912 - Improved documentation of the `base_dir` configuration option.
1913
1914 - Improved documentation of preprocessor and direct modes.
1915
1916 - Added HTML anchors to configuration options in the manual so that it is
1917   possible link to a specific option.
1918
1919 - Tweaked placement of "`(readonly)`" in output of `ccache -s`.
1920
1921 - Improved visibility of color output from the test suite.
1922
1923 - Fixed a problem when running the test suite with Clang without a libgcov
1924   library available.
1925
1926 - Fixed test suite problems on macOS.
1927
1928 - Disabled hardlink tests on AFS since it lacks such support.
1929
1930 - Disabled read-only tests on file systems that lack such support.
1931
1932
1933 == Ccache 3.7.12
1934
1935 Release date: 2020-10-01
1936
1937
1938 === Bug fixes
1939
1940 - Coverage files (`.gcno`) produced by GCC 9+ when using `-fprofile-dir=dir`
1941   are now handled gracefully by falling back to running the compiler.
1942
1943 - Fixed writing to log file larger than 2 GiB when running ccache compiled in
1944   32-bit mode.
1945
1946
1947 === Other
1948
1949 - Improved documentation about sharing a cache on NFS.
1950
1951 - Fixed test case failures with old objdump versions.
1952
1953 - Fixed test case failures with GCC 4.4.
1954
1955
1956 == Ccache 3.7.11
1957
1958 Release date: 2020-07-21
1959
1960
1961 === Bug fixes
1962
1963 - Added knowledge about `-fprofile-{correction,reorder-functions,values}`.
1964
1965 - ccache now handles the Intel compiler option `-xCODE` (where `CODE` is a
1966   processor feature code) correctly.
1967
1968 - Added support for NVCC's `-Werror` and `--Werror` options.
1969
1970
1971 === Other
1972
1973 - ccache's "`Directory is not hashed if using -gz[=zlib]`" tests are now skipped
1974   for GCC 6.
1975
1976
1977 == Ccache 3.7.10
1978
1979 Release date: 2020-06-22
1980
1981
1982 === Bug fixes
1983
1984 - Improved handling of profiling options. ccache should now work correctly for
1985   profiling options like `-fprofile-{generate,use}[=path]` for GCC ≥ 9 and
1986   Clang as well as `-fauto-profile[=path]` and the Clang-specific
1987   `-fprofile-instr-{generate,use}[=path]` and `-fprofile-sample-{use,accurate}`
1988   options.
1989
1990 - ccache now copies files directly from the cache to the destination file
1991   instead of via a temporary file. This avoids problems when using filenames
1992   long enough to be near the file system's filename max limit.
1993
1994 - When the hard-link mode is enabled, ccache now only uses hard links for
1995   object files, not other files like dependency files. This is because
1996   compilers unlink object files before writing to them but they don't do that
1997   for dependency files, so the latter can become overwritten and therefore
1998   corrupted in the cache.
1999
2000 - Fixed a glitch related to hard-link mode and an empty cache.
2001
2002 - ccache now supports the ccache.conf file to be a symlink.
2003
2004 - Temporary files are now deleted immediately on signals like SIGTERM and
2005   SIGINT instead of some time later in a cleanup phase.
2006
2007 - Fixed a bug that affected ccache's `-o/--set-config` option for the
2008   `base_dir` and `cache_dir_levels` keys.
2009
2010
2011 == Ccache 3.7.9
2012
2013 Release date: 2020-03-29
2014
2015
2016 === Bug fixes
2017
2018 - Fixed replacing of /dev/null when building as root with hard link mode
2019   enabled and using `-o /dev/null`.
2020
2021 - Removed incorrect assertion resulting in "`ccache: error: Internal error in
2022   format`" when using `-fdebug-prefix-map=X=` with X equal to `$PWD`.
2023
2024
2025 === Other
2026
2027 - Improved CUDA/NVCC support: Recognize `-dc` and `-x cu` options.
2028
2029 - Improved name of temporary file used in NFS-safe unlink.
2030
2031
2032 == Ccache 3.7.8
2033
2034 Release date: 2020-03-16
2035
2036
2037 === Bug fixes
2038
2039 - Use `$PWD` instead of the real CWD (current working directory) when checking
2040   for CWD in preprocessed output. This fixes a problem when `$PWD` includes a
2041   symlink part and the user has set `hash_dir = false`.
2042
2043 - Rewrote the Windows version of the lockfile routines. This should mitigate
2044   several problems with the old implementation.
2045
2046 - If `localtime_r` fails the epoch time is now logged instead of garbage.
2047
2048
2049 === Other
2050
2051 - Improved error message when a boolean environment variable has an invalid
2052   value.
2053
2054 - Improved the regression fix in ccache 3.7.5 related to not passing
2055   compilation-only options to the preprocessor.
2056
2057 - ccache's PCH test suite now skips running the tests if it detects broken PCH
2058   compiler support.
2059
2060 - Fixed unit test failure on Windows.
2061
2062 - Fixed "`stringop-truncation`" build warning on Windows.
2063
2064 - Improved "`x_rename`" implementation on Windows.
2065
2066 - Improved removal of temporary file when rewriting absolute paths to relative
2067   in the dependency file.
2068
2069 - Clarified "`include_file_ctime sloppiness`" in the Performance section in the
2070   manual.
2071
2072
2073 == Ccache 3.7.7
2074
2075 Release date: 2020-01-05
2076
2077
2078 === Bug fixes
2079
2080 - Fixed a bug related to object file location in the dependency file (if using
2081   `-MD` or `-MMD` but not `-MF` and the build directory is not the same as the
2082   source directory then the object file location in the `.d` file would become
2083   incorrect). This fixes regression in ccache 3.7.5 introduced by the bug fix
2084   related to EDG-based compilers. Note that this removes support for EDG-based
2085   compilers again. (A better fix for this is planned for ccache 4.0.)
2086
2087 - Removed the unify mode since it has bugs and shortcomings that are non-trivial
2088   or impossible to fix: it doesn't work with the direct mode, it doesn't handle
2089   C++ raw strings correctly, it can give false cache hits for `.incbin`
2090   directives, it's turned off when using `-g` and it can make line numbers in
2091   warning messages and `__LINE__` macros incorrect.
2092
2093 - mtime and ctime values are now stored in the manifest files only when
2094   sloppy_file_stat is set. This avoids adding superfluous manifest file entries
2095   on direct mode cache misses.
2096
2097 - A "`Result:`" line is now always printed to the log.
2098
2099 - The "`cache miss`" statistics counter will now be updated for read-only cache
2100   misses, making it consistent with the cache hit case.
2101
2102
2103 == Ccache 3.7.6
2104
2105 Release date: 2019-11-17
2106
2107
2108 === Bug fixes
2109
2110 - The opt-in "`file_macro sloppiness`" mode has been removed so that the input
2111   file path now is always included in the direct mode hash. This fixes a bug
2112   that could result in false cache hits in an edge case when "`file_macro
2113   sloppiness`" is enabled and several identical source files include a relative
2114   header file with the same name but in different directories.
2115
2116 - Statistics files are no longer lost when the filesystem of the cache is full.
2117
2118 - Bail out on too hard Clang option `-MJarg` (in addition to the previous
2119   bailout of `-MJ arg`).
2120
2121 - Properly handle color diagnostics in the depend mode as well.
2122
2123
2124 == Ccache 3.7.5
2125
2126 Release date: 2019-10-22
2127
2128
2129 === New features
2130
2131 - Added support for `-MF=arg` (with an extra equal sign) as understood by
2132   EDG-based compilers.
2133
2134
2135 === Bug fixes
2136
2137 - Fixed a regression in 3.7.2 that could result in a warning message instead of
2138   an error in an edge case related to usage of "`-Werror`".
2139
2140 - An implicit `-MQ` is now passed to the preprocessor only if the object file
2141   extension is non-standard. This will make it easier to use EDG-based
2142   compilers (e.g. GHS) which don't understand `-MQ`. (This is a bug fix of the
2143   corresponding improvement implemented in ccache 3.4.)
2144
2145 - ccache now falls back to running the real compiler instead of failing fataly
2146   if an internal temporary file is missing after compilation.
2147
2148 - Fixed a crash if localtime returns null pointer in localtime_r replacement.
2149
2150 - Fixed header file dependency tracking when building ccache itself.
2151
2152 - Fixed warning during configure in out-of-tree build in developer mode.
2153
2154
2155 == Ccache 3.7.4
2156
2157 Release date: 2019-09-12
2158
2159
2160 === Improvements
2161
2162 - Added support for the `-gz[=type]` compiler option (previously ccache would
2163   think that "`-gz`" alone would enable debug information, thus potentially
2164   including the current directory in the hash).
2165
2166 - Added support for converting paths like "`/c/users/...`" into relative paths
2167   on Windows.
2168
2169
2170 == Ccache 3.7.3
2171
2172 Release date: 2019-08-17
2173
2174
2175 === Bug fixes
2176
2177 - The cache size (which is counted in "`used disk blocks`") is now correct on
2178   filesystems that use more or less disk blocks than conventional filesystems,
2179   e.g. ecryptfs or btrfs/zfs with transparent compression. This also fixes a
2180   related problem with ccache's own test suite when run on such file systems.
2181
2182 - Fixed a regression in 3.7.2 when using the compiler option "`-Werror`" and
2183   then "`-Wno-error`" later on the command line.
2184
2185
2186 == Ccache 3.7.2
2187
2188 Release date: 2019-07-19
2189
2190
2191 === Bug fixes
2192
2193 - The compiler option `-gdwarf*` no longer forces "`run_second_cpp = true`".
2194
2195 - Added verification that the value passed to the `-o/--set-config` option is
2196   valid.
2197
2198 - Fixed detection of precompiled headers in the depend mode.
2199
2200 - Bail out on too hard Clang option `-ftime-trace`.
2201
2202 - ccache now updates the correct stats file when adding/updating manifest
2203   files. This bug previously made the file and size statistics counters
2204   incorrect over time.
2205
2206 - Fixed warnings from Clang about unused arguments during preprocessing.
2207
2208 - Unknown manifest versions are now handled gracefully in `--dump-manifest`.
2209
2210 - Fixed `make check` with "`funny`" locales.
2211
2212
2213 === Documentation
2214
2215 - Added a hint about not running `autogen.sh` when building from a release
2216   archive.
2217
2218 - Mention that `xsltproc` is needed when building from the source repository.
2219
2220
2221 == Ccache 3.7.1
2222
2223 Release date: 2019-05-01
2224
2225
2226 === Changes
2227
2228 - Fixed a problem when using the compiler option `-MF /dev/null`.
2229
2230 - Long commandlines are now handled gracefully on Windows by using the `@file`
2231   syntax to avoid hitting the commandline size limit.
2232
2233 - Fixed complaint from GCC 9's `-Werror=format-overflow` when compiling ccache
2234   itself.
2235
2236
2237 == Ccache 3.7
2238
2239 Release date: 2019-04-23
2240
2241
2242 === Changes
2243
2244 - Fixed crash when the debug mode is enabled and the output file is in a
2245   non-writable directory, e.g. when the output file is `/dev/null`.
2246
2247 - Fixed an issue when printing very large log messages to the debug log.
2248
2249 - Fixed bugs related to support for `-gsplit-dwarf`. Previously ccache could
2250   produce an incorrect link to the `.dwo` file in the `.o` file.
2251
2252 - Compilations with /dev/null as the input file are now cached.
2253
2254 - ccache has learned how to construct the object filename if no `-o` option is
2255   given and the source filename does not include a `.` or ends with a `.`.
2256
2257 - Fixed a temporary file leak when the depend mode is enabled and the compiler
2258   produces standard error output.
2259
2260 - Fixed a bug in the depend mode where a manifest hash only could be associated
2261   with one set of header dependencies.
2262
2263 - Manifest files did not get marked as used on direct cache hits, so the LRU
2264   cache cleanup would incorrectly remove them eventually. This has been fixed.
2265
2266 - The rewriting of absolute paths into relative paths in the dependency file
2267   has been enabled in the depend mode as well.
2268
2269 - ccache now ignores unknown keys in configuration files for forward
2270   compatibility.
2271
2272 - Rearranged command-line options into sections in the help text.
2273
2274 - Documented the previously undocumented `--dump-manifest` and `--hash-file`
2275   options (only useful for debugging ccache itself).
2276
2277 - Added missing documentation for the command-line option `-k/--get-config`
2278   added in ccache 3.5.
2279
2280 - Renamed the `--print-config` command to `--show-config`.
2281
2282 - Added a new `--print-stats` command that prints statistics counters in
2283   machine-parsable (tab-separated) format.
2284
2285 - ccache no longer creates a missing output directory, thus mimicking the
2286   compiler behavior for `-o out/obj.o` when `out` doesn't exist.
2287
2288 - `-fdebug-prefix-map=ARG`, `-ffile-prefix-map=ARG` and `-fmacro-prefix-map=ARG`
2289   are now included in the hash, but only the part before "`ARG`". This fixes a
2290   bug where compiler feature detection of said flags would not work correctly
2291   with ccache.
2292
2293 - Bail out on too hard compiler option `-gtoggle`.
2294
2295 - Bail out on too hard Clang options `--analyze` and `-analyze`.
2296
2297 - Improved debug logging of file hashes in depend mode.
2298
2299 - Improved handling of various `-g*` options. In particular, ccache now
2300   understands that `-g0` cancels out previous `-g* options`.
2301
2302 - Worked around a problem with Automake related to `.d` files when using the
2303   hard link mode.
2304
2305 - Added opt-in (at configure time) support for enabling trace logs for
2306   profiling ccache itself. See `doc/DEVELOPER.md` in the code tree for more
2307   information
2308
2309 - Removed support for Fortran 77 again. Some Fortran support was added in
2310   ccache 3.3, but the implementation did not work when Fortran modules are
2311   involved.
2312
2313
2314 == Ccache 3.6
2315
2316 Release date: 2019-01-14
2317
2318
2319 === Changes
2320
2321 - ccache now has an opt-in "`depend mode`". When enabled, ccache never executes
2322   the preprocessor, which results in much lower cache miss overhead at the
2323   expense of a lower potential cache hit rate. The depend mode is only possible
2324   to use when the compiler option `-MD` or `-MMD` is used.
2325
2326 - Added support for GCC's `-ffile-prefix-map` option. The `-fmacro-prefix-map`
2327   option is now also skipped from the hash.
2328
2329 - Added support for multiple `-fsanitize-blacklist` arguments.
2330
2331 - ccache now includes the environment variables `LANG`, `LC_ALL`, `LC_CTYPE`
2332   and `LC_MESSAGES` in the hash since they may affect localization of compiler
2333   warning messages. Set sloppiness to `locale` to opt out of this.
2334
2335 - Fixed a problem due to Clang overwriting the output file when compiling an
2336   assembler file.
2337
2338 - Clarified the manual to explain the reasoning behind the "`file_macro`"
2339   sloppiness setting in a better way.
2340
2341 - ccache now handles several levels of nonexistent directories when rewriting
2342   absolute paths to relative.
2343
2344 - A new sloppiness setting `clang_index_store` makes ccache skip the Clang
2345   compiler option `-index-store-path` and its argument when computing the
2346   manifest hash. This is useful if you use Xcode, which uses an index store
2347   path derived from the local project path. Note that the index store won't be
2348   updated correctly on cache hits if you enable this option.
2349
2350 - Rename sloppiness `no_system_headers` to `system_headers` for consistency
2351   with other options. `no_system_headers` can still be used as an
2352   (undocumented) alias.
2353
2354 - The GCC variables "`DEPENDENCIES_OUTPUT`" and "`SUNPRO_DEPENDENCIES`" are now
2355   supported correctly.
2356
2357 - The algorithm that scans for `__DATE_` and `+__TIME__+` tokens in the hashed
2358   source code now doesn't produce false positives for tokens where `+__DATE__+`
2359   or `+__TIME__+` is a substring.
2360
2361
2362 == Ccache 3.5.1
2363
2364 Release date: 2019-01-02
2365
2366
2367 === Changes
2368
2369 - Added missing getopt_long.c source file to release archive.
2370
2371 - Fixed (harmless) compiler warnings when building ccache object files.
2372
2373 - CFLAGS is no longer passed to the linker when linking ccache.
2374
2375 - Improved development mode build flags.
2376
2377
2378 == Ccache 3.5
2379
2380 Release date: 2018-10-15
2381
2382
2383 === Changes
2384
2385 - Added a boolean `debug` (`CCACHE_DEBUG`) configuration option. When enabled,
2386   ccache will create per-object debug files that are helpful e.g. when debugging
2387   unexpected cache misses. See also the new "`Cache debugging`" section in the
2388   manual.
2389
2390 - Renamed `CCACHE_CC` to `CCACHE_COMPILER` (keeping the former as a deprecated
2391   alias).
2392
2393 - Added a new command-line option `-k/--get-config` that prints the value of a
2394   config key.
2395
2396 - It is now possible to let ccache hash a precomputed checksum file instead of
2397   the full content of a precompiled header. This can save time for large
2398   precompiled headers. Note that the build system needs to keep the checksum
2399   file in sync with the precompiled header for this to work.
2400
2401 - Improved performance substantially when using `hash_dir = false` on platforms
2402   like macOS where `getcwd()` is slow.
2403
2404 - Added "`stats updated`" timestamp in `ccache -s` output. This can be useful if
2405   you wonder whether ccache actually was used for your last build.
2406
2407 - Renamed "`stats zero time`" to "`stats zeroed`" and documented it. The counter
2408   is also now only present in `ccache -s` output when `ccache -z` actually has
2409   been called.
2410
2411 - The content of the `-fsanitize-blacklist` file is now included in the hash,
2412   so updates to the file will now correctly result in separate cache entries.
2413
2414 - It's now possible to opt out of building and installing man pages when
2415   running `make install` in the source repository.
2416
2417 - If the compiler type can't be detected (e.g. if it is named `cc`), use safer
2418   defaults that won't trip up Clang.
2419
2420 - Made the ccache test suite work on FreeBSD.
2421
2422 - Added `file_stat_matches_ctime` option to disable ctime check if
2423   `file_stat_matches` is enabled.
2424
2425 - Made "`./configure --without-bundled-zlib`" do what's intended.
2426
2427
2428 == Ccache 3.4.3
2429
2430 Release date: 2018-09-02
2431
2432
2433 === Bug fixes
2434
2435 - Fixed a race condition when creating the initial config file in the cache
2436   directory.
2437
2438 - Bail out on too hard Clang option `-MJ`.
2439
2440 - Bail out on too hard option `-save-temps=obj`.
2441
2442 - Handle separate parameter to Clang option `-target` correctly.
2443
2444 - Upgraded bundled zlib to version 1.2.11.
2445
2446
2447 == Ccache 3.4.2
2448
2449 Release date: 2018-03-25
2450
2451
2452 === Bug fixes
2453
2454 - The cleanup algorithm has been fixed to not misbehave when files are removed
2455   by another process while the cleanup process is running. Previously, too many
2456   files could be removed from the cache if multiple cleanup processes were
2457   triggered at the same time, in extreme cases trimming the cache to a much
2458   smaller size than the configured limits.
2459
2460 - Correctly hash preprocessed headers located in a "`.gch directory`".
2461   Previously, ccache would not pick up changes to such precompiled headers,
2462   risking false positive cache hits.
2463
2464 - Fixed build failure when using the bundled zlib sources.
2465
2466 - ccache 3.3.5 added a workaround for not triggering Clang errors when a
2467   precompiled header's dependency has an updated timestamp (but identical
2468   content). That workaround is now only applied when the compiler is Clang.
2469
2470 - Made it possible to perform out-of-source builds in dev mode again.
2471
2472
2473 == Ccache 3.4.1
2474
2475 Release date: 2018-02-11
2476
2477
2478 === Bug fixes
2479
2480 - Fixed printing of version number in `ccache --version`.
2481
2482
2483 == Ccache 3.4
2484
2485 Release date: 2018-02-11
2486
2487
2488 === New features and enhancements
2489
2490 - The compiler option form `--sysroot arg` is now handled like the documented
2491   `--sysroot=arg` form.
2492
2493 - Added support for caching `.su` files generated by GCC flag `-fstack-usage`.
2494
2495 - ccache should now work with distcc's "`pump`" wrapper.
2496
2497 - The optional unifier is no longer disabled when the direct mode is enabled.
2498
2499 - Added support for NVCC compiler options `--compiler-bindir/-ccbin`,
2500   `--output-directory/-odir` and `--libdevice-directory/-ldir`.
2501
2502 - Boolean environment variable settings no longer accept the following
2503   (case-insensitive) values: `0`, `false`, `disable` and `no`. All other values
2504   are accepted and taken to mean "`true`". This is to stop users from setting
2505   e.g. `CCACHE_DISABLE=0` and then expect the cache to be used.
2506
2507 - Improved support for `run_second_cpp = false`: If combined with passing
2508   `-fdirectives-only` (GCC) or `frewrite-includes` (Clang) to the compiler,
2509   diagnostics warnings and similar will be correct.
2510
2511 - An implicit `-MQ` is now passed to the preprocessor only if the object file
2512   extension is non-standard. This should make it easier to use EDG-based
2513   compilers (e.g. GHS) which don't understand `-MQ`.
2514
2515 - ccache now treats an unreadable configuration file just like a missing
2516   configuration file.
2517
2518 - Documented more pitfalls with enabling `hard_link` (`CCACHE_HARDLINK`).
2519
2520 - Documented caveats related to colored warnings from compilers.
2521
2522
2523 === Bug fixes
2524
2525 - File size and number counters are now updated correctly when files are
2526   overwritten in the cache, e.g. when using `CCACHE_RECACHE`.
2527
2528 - `run_second_cpp` is now forced for NVCC.
2529
2530 - Fixed how the NVCC options `-optf` and `-odir` are handled.
2531
2532
2533 == Ccache 3.3.6
2534
2535 Release date: 2018-01-28
2536
2537 === New features and enhancements
2538
2539 - Improved instructions on how to get cache hits between different working
2540   directories.
2541
2542
2543 === Bug fixes
2544
2545 - Fixed regression in ccache 3.3.5 related to the `UNCACHED_ERR_FD` feature.
2546
2547
2548 == Ccache 3.3.5
2549
2550 Release date: 2018-01-13
2551
2552
2553 === New features and enhancements
2554
2555 - Documented how automatic cache cleanup works.
2556
2557
2558 === Bug fixes
2559
2560 - Fixed a regression where the original order of debug options could be lost.
2561   This reverts the "`Improved parsing of `-g*` options`" feature in ccache 3.3.
2562
2563 - Multiple `-fdebug-prefix-map` options should now be handled correctly.
2564
2565 - Fixed matching of directories in the `ignore_headers_in_manifest`
2566   configuration option.
2567
2568 - Fixed detection of missing argument to `-opt`/`--options-file`.
2569
2570 - ccache now bails out when building a precompiled header if any of the
2571   corresponding header files has an updated timestamp. This fixes complaints
2572   from Clang.
2573
2574 - Fixed a bug related to erroneously storing a dependency file with absolute
2575   paths in the cache on a preprocessed hit.
2576
2577 - `ccache -c/--cleanup` now works like documented: it just recalculates size
2578   counters and trims the cache to not exceed the max size and file number
2579   limits. Previously, the forced cleanup took "`limit_multiple`" into account,
2580   so that `ccache -c/--cleanup` by default would trim the cache to 80% of the
2581   max limit.
2582
2583 - ccache no longer ignores linker arguments for Clang since Clang warns about
2584   them.
2585
2586 - Plugged a couple of file descriptor leaks.
2587
2588 - Fixed a bug where ccache would skip hashing the compiler argument following a
2589   `-fno-working-directory`, `-fworking-directory`, `-nostdinc`, `-nostdinc++`,
2590   `-remap` or `-trigraphs` option in preprocessor mode.
2591
2592
2593 == Ccache 3.3.4
2594
2595 Release date: 2017-02-17
2596
2597 === New features and enhancements
2598
2599 - Documented the different cache statistics counters.
2600
2601
2602 === Bug fixes
2603
2604 - Fixed a regression in ccache 3.3 related to potentially bad content of
2605   dependency files when compiling identical source code but with different
2606   source paths. This was only partially fixed in 3.3.2 and reverts the new
2607   "`Names of included files are no longer included in the hash of the compiler's
2608   preprocessed output`" feature in 3.3.
2609
2610 - Corrected statistics counter for `-optf`/`--options-file` failure.
2611
2612 - Fixed undefined behavior warnings in ccache found by `-fsanitize=undefined`.
2613
2614 == Ccache 3.3.3
2615
2616 Release date: 2016-10-26
2617
2618
2619 === Bug fixes
2620
2621 - ccache now detects usage of `.incbin` assembler directives in the source code
2622   and avoids caching such compilations.
2623
2624
2625 == Ccache 3.3.2
2626
2627 Release date: 2016-09-28
2628
2629
2630 === Bug fixes
2631
2632 - Fixed a regression in ccache 3.3 related to potentially bad content of
2633   dependency files when compiling identical source code but with different
2634   source paths.
2635
2636 - Fixed a regression in ccache 3.3.1: ccache could get confused when using the
2637   compiler option `-Wp,` to pass multiple options to the preprocessor,
2638   resulting in missing dependency files from direct mode cache hits.
2639
2640
2641 == Ccache 3.3.1
2642
2643 Release date: 2016-09-07
2644
2645
2646 === Bug fixes
2647
2648 - Fixed a problem in the "`multiple `-arch` options`" support introduced in 3.3.
2649   When using the direct mode (the default), different combinations of `-arch`
2650   options were not detected properly.
2651
2652 - Fixed an issue when compiler option `-Wp,-MT,path` is used instead of `-MT
2653   path` (and similar for `-MF`, `-MP` and `-MQ`) and `run_second_cpp`
2654   (`CCACHE_CPP2`) is enabled.
2655
2656
2657 == Ccache 3.3
2658
2659 Release date: 2016-08-27
2660
2661 === Notes
2662
2663 - A C99-compatible compiler is now required to build ccache.
2664
2665
2666 === New features and enhancements
2667
2668 - The configuration option `run_second_cpp` (`CCACHE_CPP2`) now defaults to
2669   true. This improves ccache's out-of-the-box experience for compilers that
2670   can't compile their own preprocessed output with the same outcome as if they
2671   compiled the real source code directly, e.g. newer versions of GCC and Clang.
2672
2673 - The configuration option `hash_dir` (`CCACHE_HASHDIR`) now defaults to true.
2674
2675 - Added a new `ignore_headers_in_manifest` configuration option, which
2676   specifies headers that should be ignored in the direct mode.
2677
2678 - Added a new `prefix_command_cpp` (`CCACHE_PREFIX_CPP`) configuration option,
2679   which specifies one or several prefixes to add to the command line ccache
2680   uses when invoking the preprocessor.
2681
2682 - Added a new `limit_multiple` (`CCACHE_LIMIT_MULTIPLE`) configuration option,
2683   which specifies how much of the cache to remove when cleaning.
2684
2685 - Added a new `keep_comments_cpp` (`CCACHE_COMMENTS`) configuration option,
2686   which tells ccache not to discard the comments before hashing preprocessor
2687   output. This can be used to check documentation with `-Wdocumentation`.
2688
2689 - Added a new sloppiness option `no_system_headers`, which tells ccache not to
2690   include system headers in manifest files.
2691
2692 - Added a new statistics counter that tracks the number of performed cleanups
2693   due to the cache size being over the limit. The value is shown in the output
2694   of "`ccache -s`".
2695
2696 - Added support for relocating debug info directory using `-fdebug-prefix-map`.
2697   This allows for cache hits even when `hash_dir` is used in combination with
2698   `base_dir`.
2699
2700 - Added a new "`cache hit rate`" field to the output of "`ccache -s`".
2701
2702 - Added support for caching compilation of assembler code produced by e.g. "`gcc
2703   -S file.c`".
2704
2705 - Added support for cuda including the -optf/--options-file option.
2706
2707 - Added support for Fortran 77.
2708
2709 - Added support for multiple `-arch` options to produce "`fat binaries`".
2710
2711 - Multiple identical `-arch` arguments are now handled without bailing.
2712
2713 - The concatenated form of some long compiler options is now recognized, for
2714   example when using `-isystemPATH` instead of `-isystem PATH`.
2715
2716 - If hard-linking is enabled and but fails (e.g. due to cross-device linking),
2717   ccache now falls back to copying instead of running the compiler.
2718
2719 - Made the `hash_dir` option only have effect when generating debug info.
2720
2721 - ccache now knows how to convert absolute paths to relative paths inside
2722   dependency files when using `base_dir`.
2723
2724 - Improved parsing of `-g*` options.
2725
2726 - Made ccache understand `-Wp,-D*` options.
2727
2728 - ccache now understands the undocumented `-coverage` (only one dash) GCC
2729   option.
2730
2731 - Names of included files are no longer included in the hash of the compiler's
2732   preprocessed output. This leads to more potential cache hits when not using
2733   the direct mode.
2734
2735 - Increased buffer size used when reading file data. This improves performance
2736   slightly.
2737
2738
2739 === Bug fixes
2740
2741 - Bail out on too hard compiler option `-P`.
2742
2743 - Fixed Clang test suite when running on Linux.
2744
2745 - Fixed build and test for MinGW32 and Windows.
2746
2747
2748 == Ccache 3.2.9
2749
2750 Release date: 2016-09-28
2751
2752
2753 === Bug fixes
2754
2755 - Fixed a regression in ccache 3.2.8: ccache could get confused when using the
2756   compiler option `-Wp,` to pass multiple options to the preprocessor,
2757   resulting in missing dependency files from direct mode cache hits.
2758
2759
2760 == Ccache 3.2.8
2761
2762 Release date: 2016-09-07
2763
2764
2765 === Bug fixes
2766
2767 - Fixed an issue when compiler option `-Wp,-MT,path` is used instead of `-MT
2768   path` (and similar for `-MF`, `-MP` and `-MQ`) and `run_second_cpp`
2769   (`CCACHE_CPP2`) is enabled.
2770
2771 - ccache now understands the undocumented `-coverage` (only one dash) GCC
2772   option.
2773
2774
2775 == Ccache 3.2.7
2776
2777 Release date: 2016-07-20
2778
2779
2780 === Bug fixes
2781
2782 - Fixed a bug which could lead to false cache hits for compiler command lines
2783   with a missing argument to an option that takes an argument.
2784
2785 - ccache now knows how to work around a glitch in the output of GCC 6's
2786   preprocessor.
2787
2788
2789 == Ccache 3.2.6
2790
2791 Release date: 2016-07-12
2792
2793
2794 === Bug fixes
2795
2796 - Fixed build problem on QNX, which lacks "`SA_RESTART`".
2797
2798 - Bail out on compiler option `-fstack-usage` since it creates a `.su` file
2799   which ccache currently doesn't handle.
2800
2801 - Fixed a bug where (due to ccache rewriting paths) the compiler could choose
2802   incorrect include files if `CCACHE_BASEDIR` is used and the source file path
2803   is absolute and is a symlink.
2804
2805
2806 == Ccache 3.2.5
2807
2808 Release date: 2016-04-17
2809
2810
2811 === New features and enhancements
2812
2813 - Only pass Clang-specific `-stdlib=` to the preprocessor.
2814
2815 - Improved handling of stale NFS handles.
2816
2817 - Made it harder to misinterpret documentation of boolean environment settings'
2818   semantics.
2819
2820
2821 === Bug fixes
2822
2823 - Include m4 files used by configure.ac in the source dist archives.
2824
2825 - Corrected "`Performance`" section in the manual regarding `__DATE_`,
2826   `+__TIME__+` and `+__FILE__+` macros.
2827
2828 - Fixed build on Solaris 10+ and AIX 7.
2829
2830 - Fixed failure to create directories on QNX.
2831
2832 - Don't (try to) update manifest file in "`read-only`" and "`read-only direct`"
2833   modes.
2834
2835 - Fixed a bug in caching of `stat` system calls in "`file_stat_matches
2836   sloppiness mode`".
2837
2838 - Fixed bug in hashing of Clang plugins, leading to unnecessary cache misses.
2839
2840 - Fixed --print-config to show "`pch_defines sloppiness`".
2841
2842 - The man page is now built when running "`make install`" from Git repository
2843   sources.
2844
2845
2846 == Ccache 3.2.4
2847
2848 Release date: 2015-10-08
2849
2850
2851 === Bug fixes
2852
2853 - Fixed build error related to zlib on systems with older make versions
2854   (regression in ccache 3.2.3).
2855
2856 - Made conversion-to-bool explicit to avoid build warnings (and potential
2857   runtime errors) on legacy systems.
2858
2859 - Improved signal handling: Kill compiler on SIGTERM; wait for compiler to exit
2860   before exiting; die appropriately.
2861
2862 - Minor fixes related to Windows support.
2863
2864 - The correct compression level is now used if compression is requested.
2865
2866 - Fixed a bug where cache cleanup could be run too early for caches larger than
2867   64 GiB on 32-bit systems.
2868
2869
2870 == Ccache 3.2.3
2871
2872 Release date: 2015-08-16
2873
2874
2875 === New features and enhancements
2876
2877 - Added support for compiler option `-gsplit-dwarf`.
2878
2879
2880 === Bug fixes
2881
2882 - Support external zlib in nonstandard directory.
2883
2884 - Avoid calling `exit()` inside an exit handler.
2885
2886 - Let exit handler terminate properly.
2887
2888 - Bail out on compiler option `--save-temps` in addition to `-save-temps`.
2889
2890 - Only log "`Disabling direct mode`" once when failing to read potential include
2891   files.
2892
2893
2894 == Ccache 3.2.2
2895
2896 Release date: 2015-05-10
2897
2898
2899 === New features and enhancements
2900
2901 - Added support for `CCACHE_COMPILERCHECK=string:<value>`. This is a faster
2902   alternative to `CCACHE_COMPILERCHECK=<command>` if the command's output can
2903   be precalculated by the build system.
2904
2905 - Add support for caching code coverage results (compiling for gcov).
2906
2907
2908 === Bug fixes
2909
2910 - Made hash of cached result created with and without `CCACHE_CPP2` different.
2911   This makes it possible to rebuild with `CCACHE_CPP2` set without having to
2912   clear the cache to get new results.
2913
2914 - Don't try to reset a nonexistent stats file. This avoids "`No such file or
2915   directory`" messages in the ccache log when the cache directory doesn't exist.
2916
2917 - Fixed a bug where ccache deleted Clang diagnostics after compiler failures.
2918
2919 - Avoid performing an unnecessary copy of the object file on a cache miss.
2920
2921 - Bail out on too hard compiler option `-fmodules`.
2922
2923 - Bail out on too hard compiler option `-fplugin=libcc1plugin` (interaction
2924   with GDB).
2925
2926 - Fixed build error when compiling ccache with recent Clang versions.
2927
2928 - Removed signal-unsafe code from signal handler.
2929
2930 - Corrected logic for when to output cached stderr.
2931
2932 - Wipe the whole cached result on failure retrieving a cached file.
2933
2934 - Fixed build error when compiling ccache with recent Clang versions.
2935
2936
2937 == Ccache 3.2.1
2938
2939 Release date: 2014-12-10
2940
2941
2942 === Bug fixes
2943
2944 - Fixed regression in temporary file handling, which lead to incorrect
2945   permissions for stats, manifest and ccache.conf files in the cache.
2946
2947 - `CACHEDIR.TAG` files are now created in the [0-9a-f] subdirectories so that
2948   ccache.conf is not lost in backups.
2949
2950 - Made the default cache size suffix `G`, as previously documented.
2951
2952 - `-fdiagnostics-color=auto` is now passed to the compiler even if stderr is
2953   redirected. This fixes a problem when, for instance, a configure test probes
2954   if the compiler (wrapped via ccache) supports `-fdiagnostics-color=auto`.
2955
2956 - Added missing documentation for `max_files` and `max_size` configuration
2957   options.
2958
2959
2960 == Ccache 3.2
2961
2962 Release date: 2014-11-17
2963
2964
2965 === New features and enhancements
2966
2967 - Added support for configuring ccache via one or several configuration files
2968   instead of via environment variables. Environment variables still have
2969   priority but are no longer the recommended way of customizing ccache
2970   behavior. See the manual for more information.
2971
2972 - Added support for compiler error/warning messages with color.
2973
2974 - Made creation of temporary directories and cache directories smarter to avoid
2975   unnecessary `stat` calls.
2976
2977 - Improved efficiency of the algorithm that scans for `__DATE_` and `+__TIME__+`
2978   tokens in the hashed source code.
2979
2980 - Added support for several binaries (separated by space) in `CCACHE_PREFIX`.
2981
2982 - The `-c` option is no longer passed to the preprocessor. This fixes problems
2983   with Clang and Solaris's C++ compiler.
2984
2985 - ccache no longer passes preprocessor options like `-D` and `-I` to the
2986   compiler when compiling preprocessed output. This fixes warnings emitted by
2987   Clang.
2988
2989 - Compiler options `-fprofile-generate`, `-fprofile-arcs`, `-fprofile-use` and
2990   `-fbranch-probabilities` are now handled without bailing.
2991
2992 - Added support for Clang's `--serialize-diagnostic` option, storing the
2993   diagnostic file (`.dia`) in the cache.
2994
2995 - Added support for precompiled headers when using Clang.
2996
2997 - Added support for Clang `.pth` (pretokenized header) files.
2998
2999 - Changed the `-x` language option to use the new objective C standard for GCC
3000   and Clang.
3001
3002 - On a cache miss, ccache now instructs the compiler to create the object file
3003   at the real destination and then copies the file into the cache instead of
3004   the other way around. This is needed to support compiler options like
3005   `-fprofile-arcs` and `--serialize-diagnostics`.
3006
3007 - ccache now checks that included files' ctimes aren't too new. This check can
3008   be turned off by adding `include_file_ctime` to the "`ccache sloppiness`"
3009   setting.
3010
3011 - Added possibility to get cache hits based on filename, size, mtime and ctime
3012   only. On other words, source code files are not even read, only stat-ed. This
3013   operation mode is opt-in by adding `file_stat_matches` to the "`ccache
3014   sloppiness`" setting.
3015
3016 - The filename part of options like `-Wp,-MDfilename` is no longer included in
3017   the hash since the filename doesn't have any bearing on the result.
3018
3019 - Added a "`read-only direct`" configuration setting, which is like the ordinary
3020   read-only setting except that ccache will only try to retrieve results from
3021   the cache using the direct mode, not the preprocessor mode.
3022
3023 - The display and interpretation of cache size has been changed to use SI
3024   units.
3025
3026 - Default cache size is now 5 GB (was previously 1 GiB).
3027
3028 - Added configuration option to set the compression level of compressed object
3029   files in the cache.
3030
3031 - Added support for `@file` and `-@file` arguments (reading options from a
3032   file).
3033
3034 - `-Wl,` options are no longer included in the hash since they don't affect
3035   compilation.
3036
3037 - Bail out on too hard compiler option `-Wp,-P`.
3038
3039 - Optimized MD4 calculation code on little-endian systems.
3040
3041 - Various improvements and fixes on win32.
3042
3043 - Improved logging to the ccache log file.
3044
3045 - Added `--dump-manifest` command-line option for debugging purposes.
3046
3047 - Added `--with-bundled-zlib` configure option.
3048
3049 - Upgraded bundled zlib to version 1.2.8.
3050
3051 - Improved `dev.mk` to be more platform independent.
3052
3053 - Made the test suite work with Clang and gcc-llvm on OS X.
3054
3055 - Various other improvements of the test suite.
3056
3057
3058 === Bug fixes
3059
3060 - Any previous `.stderr` is now removed from the cache when recaching.
3061
3062 - Fixed an issue when handling the `-arch` compiler option with an argument.
3063
3064 - Fixed race condition when creating the initial cache directory.
3065
3066 - Fixed test suite failures when `CC` is a ccache-wrapped compiler.
3067
3068
3069 == Ccache 3.1.12
3070
3071 Release date: 2016-07-12
3072
3073
3074 === Bug fixes
3075
3076 - Fixed a bug where (due to ccache rewriting paths) the compiler could choose
3077   incorrect include files if `CCACHE_BASEDIR` is used and the source file path
3078   is absolute and is a symlink.
3079
3080
3081 == Ccache 3.1.11
3082
3083 Release date: 2015-03-07
3084
3085
3086 === Bug fixes
3087
3088 - Fixed bug which could result in false cache hits when source code contains
3089   `'"'` followed by `" /*"` or `" //"` (with variations).
3090
3091 - Made hash of cached result created with and without `CCACHE_CPP2` different.
3092   This makes it possible to rebuild with `CCACHE_CPP2` set without having to
3093   clear the cache to get new results.
3094
3095 - Don't try to reset a nonexistent stats file. This avoids "`No such file or
3096   directory`" messages in the ccache log when the cache directory doesn't exist.
3097
3098
3099 == Ccache 3.1.10
3100
3101 Release date: 2014-10-19
3102
3103
3104 === New features and enhancements
3105
3106 - Added support for the `-Xclang` compiler option.
3107
3108 - Improved handling of exit code of internally executed processes.
3109
3110 - Zero length object files in the cache are now rejected as invalid.
3111
3112 - Bail out on option `-gsplit-dwarf` (since it produces multiple output files).
3113
3114 - Compiler option `-fdebug-prefix-map` is now ignored (not part of the hash).
3115   (The `-fdebug-prefix-map` option may be used in combination with
3116   `CCACHE_BASEDIR` to reuse results across different directories.)
3117
3118 - Added note in documentation that `--ccache-skip` currently does not mean
3119   "`don't hash the following option`".
3120
3121 - To enable support for precompiled headers (PCH), `CCACHE_SLOPPINESS` now also
3122   needs to include the new `pch_defines` sloppiness. This is because ccache
3123   can't detect changes in the source code when only defined macros have been
3124   changed.
3125
3126 - Stale files in the internal temporary directory (`<ccache_dir>/tmp`) are now
3127   cleaned up if they are older than one hour.
3128
3129
3130 === Bug fixes
3131
3132 - Fixed path canonicalization in `make_relative_path()` when path doesn't
3133   exist.
3134
3135 - Fixed bug in `common_dir_prefix_length()`. This corrects the `CCACHE_BASEDIR`
3136   behavior.
3137
3138 - ccache no longer tries to create the cache directory when `CCACHE_DISABLE` is
3139   set.
3140
3141 - Fixed bug when reading manifests with a very large number of file info
3142   entries.
3143
3144 - Fixed problem with logging of current working directory.
3145
3146
3147 == Ccache 3.1.9
3148
3149 Release date: 2013-01-06
3150
3151
3152 === Bug fixes
3153
3154 - The EAGAIN signal is now handled correctly when emitting cached stderr
3155   output. This fixes a problem triggered by large error outputs from the
3156   compiler.
3157
3158 - Subdirectories in the cache are no longer created in read-only mode.
3159
3160 - Fixed so that ccache's log file descriptor is not made available to the
3161   compiler.
3162
3163 - Improved error reporting when failing to create temporary stdout/stderr files
3164   when executing the compiler.
3165
3166 - Disappearing temporary stdout/stderr files are now handled gracefully.
3167
3168
3169 === Other
3170
3171 - Fixed test suite to work on ecryptfs.
3172
3173
3174 == Ccache 3.1.8
3175
3176 Release date: 2012-08-11
3177
3178
3179 === New features and enhancements
3180
3181 - Made paths to dependency files relative in order to increase cache hits.
3182
3183 - Added work-around to make ccache work with buggy GCC 4.1 when creating a
3184   pre-compiled header.
3185
3186 - Clang plugins are now hashed to catch plugin upgrades.
3187
3188
3189 === Bug fixes
3190
3191 - Fixed crash when the current working directory has been removed.
3192
3193 - Fixed crash when stderr is closed.
3194
3195 - Corrected a corner case when parsing backslash escapes in string
3196   literals.
3197
3198 - Paths are now correctly canonicalized when computing paths relative to the
3199   base directory.
3200
3201
3202 === Other
3203
3204 - Made git version macro work when compiling outside of the source directory.
3205
3206 - Fixed `static_assert` macro definition clash with GCC 4.7.
3207
3208
3209 == Ccache 3.1.7
3210
3211 Release date: 2012-01-08
3212
3213
3214 === Bug fixes
3215
3216 - Non-writable `CCACHE_DIR` is now handled gracefully when `CCACHE_READONLY` is
3217   set.
3218
3219 - Made failure to create files (typically due to bad directory permissions) in
3220   the cache directory fatal. Previously, such failures were silently and
3221   erroneously flagged as "`compiler produced stdout`".
3222
3223 - Both the `-specs=file` and `--specs=file` forms are now recognized.
3224
3225 - Added recognition and hashing of GCC plugins specified with `-fplugin=file`.
3226
3227 - `CCACHE_COMPILERCHECK` now also determines how to hash explicit specs files
3228   (`-specs=file`).
3229
3230 - Added `CPATH`, `C_INCLUDE_PATH` and similar environment variables to the hash
3231   to avoid false cache hits when such variables have changed.
3232
3233 - Corrected log message when unify mode is enabled.
3234
3235 - Reverted the GCC bug compatibility introduced in ccache 3.1.5 for `-MT`/`-MQ`
3236   options with concatenated arguments. (The bug is fixed in recent GCC
3237   versions.)
3238
3239
3240 === Other
3241
3242 - Corrected license header for `mdfour.c`.
3243
3244 - Improved documentation on how to fix bad object files in the cache.
3245
3246
3247
3248 == Ccache 3.1.6
3249
3250 Release date: 2011-08-21
3251
3252
3253 === New features and enhancements
3254
3255 - Rewrite argument to `--sysroot` if `CCACHE_BASEDIR` is used.
3256
3257
3258 === Bug fixes
3259
3260 - Don't crash if `getcwd()` fails.
3261
3262 - Fixed alignment of "`called for preprocessing`" counter.
3263
3264
3265 == Ccache 3.1.5
3266
3267 Release date: 2011-05-29
3268
3269
3270 === New features and enhancements
3271
3272 - Added a new statistics counter named "`called for preprocessing`".
3273
3274 - The original command line is now logged to the file specified with
3275   `CCACHE_LOGFILE`.
3276
3277 - Improved error logging when system calls fail.
3278
3279 - Added support for rewriting absolute paths in `-F`/`-iframework` GCC
3280   options.
3281
3282 - Improved order of statistics counters in `ccache -s` output.
3283
3284
3285 === Bug fixes
3286
3287 - The `-MF`/`-MT`/`-MQ` options with concatenated argument are now handled
3288   correctly when they are last on the command line.
3289
3290 - ccache is now bug compatible with GCC for the `-MT`/`-MQ` options with
3291   concatenated arguments.
3292
3293 - Fixed a minor memory leak.
3294
3295 - Systems that lack (and don't need to be linked with) libm are now supported.
3296
3297
3298 == Ccache 3.1.4
3299
3300 Release date: 2011-01-09
3301
3302
3303 === Bug fixes
3304
3305 - Made a work-around for a bug in `gzputc()` in zlib 1.2.5.
3306
3307 - Corrupt manifest files are now removed so that they won't block direct mode
3308   hits.
3309
3310 - ccache now copes with file systems that don't know about symbolic links.
3311
3312 - The file handle is now correctly closed on write error when trying to create
3313   a cache dir tag.
3314
3315
3316 == Ccache 3.1.3
3317
3318 Release date: 2010-11-28
3319
3320
3321 === Bug fixes
3322
3323 - The -MFarg, -MTarg and -MQarg compiler options (i.e, without space between
3324   option and argument) are now handled correctly.
3325
3326
3327 === Other
3328
3329 - Portability fixes for HP-UX 11.00 and other less common systems.
3330
3331
3332 == Ccache 3.1.2
3333
3334 Release date: 2010-11-21
3335
3336
3337 === Bug fixes
3338
3339 - Bail out on too hard compiler options `-fdump-*`.
3340
3341 - NULL return values from malloc/calloc of zero bytes are now handled
3342   correctly.
3343
3344 - Fixed issue when parsing precompiler output on AIX.
3345
3346
3347 === Other
3348
3349 - Improved documentation on which information is included in the hash sum.
3350
3351 - Made the "`too new header file`" test case work on file systems with
3352   unsynchronized clocks.
3353
3354 - The test suite now also works on systems that lack a /dev/zero.
3355
3356
3357 == Ccache 3.1.1
3358
3359 Release date: 2010-11-07
3360
3361
3362 === Bug fixes
3363
3364 - ccache now falls back to preprocessor mode when a non-regular include file
3365   (device, socket, etc) has been detected so that potential hanging due to
3366   blocking reads is avoided.
3367
3368 - CRC errors are now detected when decompressing compressed files in the cache.
3369
3370 - Fixed potential object file corruption race on NFS.
3371
3372 - Minor documentation corrections.
3373
3374 - Fixed configure detection of ar.
3375
3376 - ccache development version (set by dev.mk) now works with gits whose
3377   `describe` command doesn't understand `--dirty`.
3378
3379
3380 === Other
3381
3382 - Minor debug log message improvements.
3383
3384
3385 == Ccache 3.1
3386
3387 Release date: 2010-09-16
3388
3389
3390 === New features and enhancements
3391
3392 - Added support for hashing the output of a custom command (e.g. `%compiler%
3393   --version`) to identify the compiler instead of stat-ing or hashing the
3394   compiler binary. This can improve robustness when the compiler (as seen by
3395   ccache) actually isn't the real compiler but another compiler wrapper.
3396
3397 - Added support for caching compilations that use precompiled headers. (See the
3398   manual for important instructions regarding this.)
3399
3400 - Locking of the files containing statistics counters is now done using
3401   symlinks instead of POSIX locks. This should make ccache behave a lot better
3402   on file systems where POSIX locks are slow or broken (e.g. NFS on some
3403   systems).
3404
3405 - Manifest files are now updated without the need of taking locks.
3406
3407 - Updates of statistics counters are now always done in one of the sub-level
3408   statistics files. This reduces lock contention, which especially improves
3409   performance on slow NFS mounts.
3410
3411 - Reading and writing of statistics counters has been made forward-compatible
3412   (unknown counters are retained).
3413
3414 - Files are now read without using `mmap()`. This has two benefits: it's more
3415   robust against file changes during reading and it improves performance on
3416   poor systems where `mmap()` doesn't use the disk cache.
3417
3418 - Added `.cp` and `.CP` as known C++ suffixes.
3419
3420 - Improved logging.
3421
3422 - Added `-install_name` as an option known to take an argument. (This improves
3423   statistics when using the Darwin linker.)
3424
3425
3426 === Bug fixes
3427
3428 - Non-fatal error messages are now never printed to stderr but logged instead.
3429
3430 - Fixed a bug affecting failing commands when `--ccache-skip` is used.
3431
3432 - Made `--ccache-skip` work for all options.
3433
3434 - EINTR is now handled correctly.
3435
3436
3437 === Other
3438
3439 - Work on porting ccache to win32 (native), mostly done by Ramiro Polla. The
3440   port is not yet finished, but will hopefully be complete in some subsequent
3441   release.
3442
3443 - Added a `--nostats` flag to the performance benchmark program.
3444
3445 - Made the performance benchmark program more accurate when measuring cache
3446   hits.
3447
3448 - Added a new test framework for unit tests written in C.
3449
3450 - Got rid of `configure-dev`; dev mode is now given by `dev.mk.in` presence.
3451
3452 - Improved documentation on how to combine ccache with other compiler wrappers
3453   (like `distcc`).
3454
3455 - New `LICENSE.txt` file with licensing and copyright details about bundled
3456   source code.
3457
3458 - New `AUTHORS.txt` file with a list of ccache contributors.
3459
3460 - New `HACKING.txt` file with some notes about ccache code conventions.
3461
3462
3463 == Ccache 3.0.1
3464
3465 Release date: 2010-07-15
3466
3467
3468 === Bug fixes
3469
3470 - The statistics counter "`called for link`" is now correctly updated when
3471   linking with a single object file.
3472
3473 - Fixed a problem with out-of-source builds.
3474
3475
3476 == Ccache 3.0
3477
3478 Release date: 2010-06-20
3479
3480
3481 General
3482 ~~~~~~~
3483
3484 - ccache is now licensed under the GNU General Public License (GPL) version 3
3485   or later.
3486
3487
3488 === Upgrade notes
3489
3490 - The way the hashes are calculated has changed, so you won't get cache hits
3491   for compilation results stored by older ccache versions. Because of this, you
3492   might as well clear the old cache directory with `ccache --clear` if you
3493   want, unless you plan to keep using an older ccache version.
3494
3495
3496 === New features and enhancements
3497
3498 - ccache now has a "`direct mode`" where it computes a hash of the source code
3499   (including all included files) and compiler options without running the
3500   preprocessor. By not running the preprocessor, CPU usage is reduced; the
3501   speed is somewhere between 1 and 5 times that of ccache running in
3502   traditional mode, depending on the circumstances. The speedup will be higher
3503   when I/O is fast (e.g., when files are in the disk cache). The direct mode
3504   can be disabled by setting +CCACHE_NODIRECT+.
3505
3506 - Support has been added for rewriting absolute paths to relative paths when
3507   hashing, in order to increase cache hit rate when building the same source
3508   code in different directories even when compiling with `-g` and when using
3509   absolute include directory paths. This is done by setting the
3510   `CCACHE_BASEDIR` environment variable to an absolute path that specifies
3511   which paths to rewrite.
3512
3513 - Object files are now optionally stored compressed in the cache. The runtime
3514   cost is negligible, and more files will fit in the ccache directory and in
3515   the disk cache. Set `CCACHE_COMPRESS` to enable object file compression. Note
3516   that you can't use compression in combination with the hard link feature.
3517
3518 - A `CCACHE_COMPILERCHECK` option has been added. This option tells ccache what
3519   compiler-identifying information to hash to ensure that results retrieved
3520   from the cache are accurate. Possible values are: none (don't hash anything),
3521   mtime (hash the compiler's mtime and size) and content (hash the content of
3522   the compiler binary). The default is mtime.
3523
3524 - It is now possible to specify extra files whose contents should be included
3525   in the hash sum by setting the `CCACHE_EXTRAFILES` option.
3526
3527 - Added support for Objective-C and Objective-C\+\+. The statistics counter
3528   "`not a C/C++ file`" has been renamed to "`unsupported source language`".
3529
3530 - Added support for the `-x` compiler option.
3531
3532 - Added support for long command-line options.
3533
3534 - A `CACHEDIR.TAG` file is now created in the cache directory. See
3535   <http://www.brynosaurus.com/cachedir/>.
3536
3537 - Messages printed to the debug log (specified by `CCACHE_LOGFILE`) have been
3538   improved.
3539
3540 - You can relax some checks that ccache does in direct mode by setting
3541   `CCACHE_SLOPPINESS`. See the manual for more information.
3542
3543 - `CCACHE_TEMPDIR` no longer needs to be on the same filesystem as
3544   `CCACHE_DIR`.
3545
3546 - The default value of `CCACHE_TEMPDIR` has been changed to `$CCACHE_DIR/tmp`
3547   to avoid cluttering the top directory.
3548
3549 - Temporary files that later will be moved into the cache are now created in
3550   the cache directory they will end up in. This makes ccache more friendly to
3551   Linux's directory layout.
3552
3553 - Improved the test suite and added tests for most of the new functionality.
3554   It's now also possible to specify a subset of tests to run.
3555
3556 - Standard error output from the compiler is now only stored in the cache if
3557   it's non-empty.
3558
3559 - If the compiler produces no object file or an empty object file, but gives a
3560   zero exit status (could be due to a file system problem, a buggy program
3561   specified by `CCACHE_PREFIX`, etc.), ccache copes with it properly.
3562
3563 - Added `installcheck` and `distcheck` make targets.
3564
3565 - Clarified cache size limit options' and cleanup semantics.
3566
3567 - Improved display of cache max size values.
3568
3569 - The following options are no longer hashed in the preprocessor mode:
3570   `-imacros`, `-imultilib`, `-iprefix`, `-iquote`, `-isysroot`, `-iwithprefix`,
3571   `-iwithprefixbefore`, `-nostdinc`, `-nostdinc++` and `-U`.
3572
3573
3574 === Bug fixes
3575
3576 - Various portability improvements.
3577
3578 - Improved detection of home directory.
3579
3580 - User-defined `CPPFLAGS` and `LDFLAGS` are now respected in the Makefile.
3581
3582 - Fixed NFS issues.
3583
3584 - Computation of the hash sum has been improved to decrease the risk of hash
3585   collisions. For instance, the compiler options `-X -Y` and `-X-Y` previously
3586   contributed equally to the hash sum.
3587
3588 - Bail out on too hard compiler options `--coverage`, `-fprofile-arcs`,
3589   `-fprofile-generate`, `-fprofile-use`, `-frepo`, `-ftest-coverage` and
3590   `-save-temps`. Also bail out on `@file` style options.
3591
3592 - Errors when using multiple `-arch` compiler options are now noted as
3593   "`unsupported compiler option`".
3594
3595 - `-MD`/`-MMD` options without `-MT`/`-MF` are now handled correctly.
3596
3597 - The `-finput-charset` option is now handled correctly.
3598
3599 - Added support for `-Wp,-MD` and `-Wp,-MMD` options.
3600
3601 - The compiler options `-Xassembler`, `-b`, `-G` and `-V` are now correctly
3602   recognized as taking an argument.
3603
3604 - Debug information containing line numbers of predefined and command-line
3605   macros (enabled with the compiler option `-g3`) will now be correct.
3606
3607 - Corrected LRU cleanup handling of object files.
3608
3609 - `utimes()` is now used instead of `utime()` when available.
3610
3611 - Non-writable cache directories are now handled gracefully.
3612
3613 - Corrected documentation about sharing the cache directory.
3614
3615 - Fixed compilation warnings from GCC 4.3.
3616
3617 - The command specified by `CCACHE_PREFIX` is no longer part of the hash.
3618
3619 - Fixed bad memory access spotted by Valgrind.
3620
3621 - Fixed a bug in `x_realloc`.
3622
3623 - Freed memory is no longer referenced when compiling a `.i`/`.ii` file and
3624   falling back to running the real compiler.
3625
3626 - The test suite is now immune to external values of the `CCACHE_*` environment
3627   variables.
3628
3629 - Improved detection of recursive invocation.
3630
3631 - The ccache binary is now not unconditionally stripped when installing.
3632
3633 - Statistics counters are now correctly updated for -E option failures and
3634   internal errors.