Imported Upstream version 3.2
[platform/upstream/ccache.git] / NEWS.txt
1 ccache news
2 ===========
3
4
5 ccache 3.2
6 ----------
7 Release date: 2014-11-17
8
9
10 New features and improvements
11 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
12
13 - Added support for configuring ccache via one or several configuration files
14   instead of via environment variables. Environment variables still have
15   priority but are no longer the recommended way of customizing ccache
16   behavior. See the manual for more information.
17
18 - Added support for compiler error/warning messages with color.
19
20 - Made creation of temporary directories and cache directories smarter to avoid
21   unnecessary `stat` calls.
22
23 - Improved efficiency of the algorithm that scans for `__DATE_` and `__TIME__`
24   tokens in the hashed source code.
25
26 - Added support for several binaries (separated by space) in `CCACHE_PREFIX`.
27
28 - The `-c` option is no longer passed to the preprocessor. This fixes problems
29   with clang and Solaris's C++ compiler.
30
31 - ccache no longer passes preprocessor options like `-D` and `-I` to the
32   compiler when compiling preprocessed output. This fixes warnings emitted by
33   clang.
34
35 - Compiler options `-fprofile-generate`, `-fprofile-arcs`, `-fprofile-use` and
36   `-fbranch-probabilities` are now handled without bailing.
37
38 - Added support for clang's `--serialize-diagnostic` option, storing the
39   diagnostic file (`.dia`) in the cache.
40
41 - Added support for precompiled headers when using clang.
42
43 - Added support for clang `.pth` (pretokenized header) files.
44
45 - Changed the `-x` language option to use the new objective C standard for GCC
46   and clang.
47
48 - On a cache miss, ccache now instructs the compiler to create the object file
49   at the real destination and then copies the file into the cache instead of
50   the other way around. This is needed to support compiler options like
51   `-fprofile-arcs` and `--serialize-diagnostics`.
52
53 - ccache now checks that included files' ctimes aren't too new. This check can
54   be turned off by adding `include_file_ctime` to the ``ccache sloppiness''
55   setting.
56
57 - Added possibility to get cache hits based on filename, size, mtime and ctime
58   only. On other words, source code files are not even read, only stat-ed. This
59   operation mode is opt-in by adding `file_stat_matches` to the ``ccache
60   sloppiness'' setting.
61
62 - The filename part of options like `-Wp,-MDfilename` is no longer included in
63   the hash since the filename doesn't have any bearing on the result.
64
65 - Added a ``read-only direct'' configuration setting, which is like the
66   ordinary read-only setting except that ccache will only try to retrieve
67   results from the cache using the direct mode, not the preprocessor mode.
68
69 - The display and interpretation of cache size has been changed to use SI
70   units.
71
72 - Default cache size is now 5 GB (was previously 1 GiB).
73
74 - Added configuration option to set the compression level of compressed object
75   files in the cache.
76
77 - Added support for `@file` and `-@file` arguments (reading options from a
78   file).
79
80 - `-Wl,` options are no longer included in the hash since they don't affect
81   compilation.
82
83 - Bail out on too hard compiler option `-Wp,-P`.
84
85 - Optimized MD4 calculation code on little-endian systems.
86
87 - Various improvements and fixes on win32.
88
89 - Improved logging to the ccache log file.
90
91 - Added `--dump-manifest` command-line option for debugging purposes.
92
93 - Added `--with-bundled-zlib` configure option.
94
95 - Upgraded bundled zlib to version 1.2.8.
96
97 - Improved `dev.mk` to be more platform independent.
98
99 - Made the test suite work with clang and gcc-llvm on OS X.
100
101 - Various other improvements of the test suite.
102
103
104 Bug fixes
105 ~~~~~~~~~
106
107 - Any previous `.stderr` is now removed from the cache when recaching.
108
109 - Fixed an issue when handling the `-arch` compiler option with an argument.
110
111 - Fixed race condition when creating the initial cache directory.
112
113 - Fixed test suite failures when `CC` is a ccache-wrapped compiler.
114
115
116 ccache 3.1.10
117 -------------
118 Release date: 2014-10-19
119
120
121 New features and improvements
122 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
123
124 - Added support for the `-Xclang` compiler option.
125
126 - Improved handling of exit code of internally executed processes.
127
128 - Zero length object files in the cache are now rejected as invalid.
129
130 - Bail out on option `-gsplit-dwarf` (since it produces multiple output files).
131
132 - Compiler option `-fdebug-prefix-map` is now ignored (not part of the hash).
133   (The `-fdebug-prefix-map` option may be used in combination with
134   `CCACHE_BASEDIR` to reuse results across different directories.)
135
136 - Added note in documentation that `--ccache-skip` currently does not mean
137   ``don't hash the following option''.
138
139 - To enable support for precompiled headers (PCH), `CCACHE_SLOPPINESS` now also
140   needs to include the new `pch_defines` sloppiness. This is because ccache
141   can't detect changes in the source code when only defined macros have been
142   changed.
143
144 - Stale files in the internal temporary directory (`<ccache_dir>/tmp`) are now
145   cleaned up if they are older than one hour.
146
147
148 Bug fixes
149 ~~~~~~~~~
150
151 - Fixed path canonicalization in `make_relative_path()` when path doesn't
152   exist.
153
154 - Fixed bug in `common_dir_prefix_length()`. This corrects the `CCACHE_BASEDIR`
155   behavior.
156
157 - ccache no longer tries to create the cache directory when `CCACHE_DISABLE` is
158   set.
159
160 - Fixed bug when reading manifests with a very large number of file info
161   entries.
162
163 - Fixed problem with logging of current working directory.
164
165
166 ccache 3.1.9
167 ------------
168 Release date: 2013-01-06
169
170
171 Bug fixes
172 ~~~~~~~~~
173
174 - The EAGAIN signal is now handled correctly when emitting cached stderr
175   output. This fixes a problem triggered by large error outputs from the
176   compiler.
177
178 - Subdirectories in the cache are no longer created in read-only mode.
179
180 - Fixed so that ccache's log file descriptor is not made available to the
181   compiler.
182
183 - Improved error reporting when failing to create temporary stdout/stderr files
184   when executing the compiler.
185
186 - Disappearing temporary stdout/stderr files are now handled gracefully.
187
188
189 Other
190 ~~~~~
191
192 - Fixed test suite to work on ecryptfs.
193
194
195 ccache 3.1.8
196 ------------
197 Release date: 2012-08-11
198
199
200 New features and improvements
201 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
202
203 - Made paths to dependency files relative in order to increase cache hits.
204
205 - Added work-around to make ccache work with buggy GCC 4.1 when creating a
206   pre-compiled header.
207
208 - Clang plugins are now hashed to catch plugin upgrades.
209
210
211 Bug fixes
212 ~~~~~~~~~
213
214 - Fixed crash when the current working directory has been removed.
215
216 - Fixed crash when stderr is closed.
217
218 - Corrected a corner case when parsing backslash escapes in string
219   literals.
220
221 - Paths are now correctly canonicalized when computing paths relative to the
222   base directory.
223
224
225 Other
226 ~~~~~
227
228 - Made git version macro work when compiling outside of the source directory.
229
230 - Fixed `static_assert` macro definition clash with GCC 4.7.
231
232
233 ccache 3.1.7
234 ------------
235 Release date: 2012-01-08
236
237
238 Bug fixes
239 ~~~~~~~~~
240
241 - Non-writable `CCACHE_DIR` is now handled gracefully when `CCACHE_READONLY` is
242   set.
243
244 - Made failure to create files (typically due to bad directory permissions) in
245   the cache directory fatal. Previously, such failures were silently and
246   erroneously flagged as "compiler produced stdout".
247
248 - Both the `-specs=file` and `--specs=file` forms are now recognized.
249
250 - Added recognition and hashing of GCC plugins specified with `-fplugin=file`.
251
252 - `CCACHE_COMPILERCHECK` now also determines how to hash explicit specs files
253   (`-specs=file`).
254
255 - Added `CPATH`, `C_INCLUDE_PATH` and similar environment variables to the hash
256   to avoid false cache hits when such variables have changed.
257
258 - Corrected log message when unify mode is enabled.
259
260 - Reverted the GCC bug compatibility introduced in ccache 3.1.5 for `-MT`/`-MQ`
261   options with concatenated arguments. (The bug is fixed in recent GCC
262   versions.)
263
264
265 Other
266 ~~~~~
267
268 - Corrected license header for `mdfour.c`.
269
270 - Improved documentation on how to fix bad object files in the cache.
271
272
273
274 ccache 3.1.6
275 ------------
276 Release date: 2011-08-21
277
278
279 New features and improvements
280 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
281
282 - Rewrite argument to `--sysroot` if `CCACHE_BASEDIR` is used.
283
284
285 Bug fixes
286 ~~~~~~~~~
287
288 - Don't crash if `getcwd()` fails.
289
290 - Fixed alignment of ``called for preprocessing'' counter.
291
292
293 ccache 3.1.5
294 ------------
295 Release date: 2011-05-29
296
297
298 New features and improvements
299 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
300
301 - Added a new statistics counter named ``called for preprocessing''.
302
303 - The original command line is now logged to the file specified with
304   `CCACHE_LOGFILE`.
305
306 - Improved error logging when system calls fail.
307
308 - Added support for rewriting absolute paths in `-F`/`-iframework` GCC
309   options.
310
311 - Improved order of statistics counters in `ccache -s` output.
312
313
314 Bug fixes
315 ~~~~~~~~~
316
317 - The `-MF`/`-MT`/`-MQ` options with concatenated argument are now handled
318   correctly when they are last on the command line.
319
320 - ccache is now bug compatible with GCC for the `-MT`/`-MQ` options with
321   concatenated arguments.
322
323 - Fixed a minor memory leak.
324
325 - Systems that lack (and don't need to be linked with) libm are now supported.
326
327
328 ccache 3.1.4
329 ------------
330 Release date: 2011-01-09
331
332
333 Bug fixes
334 ~~~~~~~~~
335
336 - Made a work-around for a bug in `gzputc()` in zlib 1.2.5.
337
338 - Corrupt manifest files are now removed so that they won't block direct mode
339   hits.
340
341 - ccache now copes with file systems that don't know about symbolic links.
342
343 - The file handle in now correctly closed on write error when trying to create
344   a cache dir tag.
345
346
347 ccache 3.1.3
348 ------------
349 Release date: 2010-11-28
350
351
352 Bug fixes
353 ~~~~~~~~~
354
355 - The -MFarg, -MTarg and -MQarg compiler options (i.e, without space between
356   option and argument) are now handled correctly.
357
358
359 Other
360 ~~~~~
361
362 - Portability fixes for HP-UX 11.00 and other esoteric systems.
363
364
365 ccache 3.1.2
366 ------------
367 Release date: 2010-11-21
368
369
370 Bug fixes
371 ~~~~~~~~~
372
373 - Bail out on too hard compiler options `-fdump-*`.
374
375 - NULL return values from malloc/calloc of zero bytes are now handled
376   correctly.
377
378 - Fixed issue when parsing precompiler output on AIX.
379
380
381 Other
382 ~~~~~
383
384 - Improved documentation on which information is included in the hash sum.
385
386 - Made the ``too new header file'' test case work on file systems with
387   unsynchronized clocks.
388
389 - The test suite now also works on systems that lack a /dev/zero.
390
391
392 ccache 3.1.1
393 ------------
394 Release date: 2010-11-07
395
396
397 Bug fixes
398 ~~~~~~~~~
399
400 - ccache now falls back to preprocessor mode when a non-regular include file
401   (device, socket, etc) has been detected so that potential hanging due to
402   blocking reads is avoided.
403
404 - CRC errors are now detected when decompressing compressed files in the cache.
405
406 - Fixed potential object file corruption race on NFS.
407
408 - Minor documentation corrections.
409
410 - Fixed configure detection of ar.
411
412 - ccache development version (set by dev.mk) now works with gits whose
413   `describe` command doesn't understand `--dirty`.
414
415
416 Other
417 ~~~~~
418
419 - Minor debug log message improvements.
420
421
422 ccache 3.1
423 ----------
424 Release date: 2010-09-16
425
426
427 New features and improvements
428 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
429
430 - Added support for hashing the output of a custom command (e.g. `%compiler%
431   --version`) to identify the compiler instead of stat-ing or hashing the
432   compiler binary. This can improve robustness when the compiler (as seen by
433   ccache) actually isn't the real compiler but another compiler wrapper.
434
435 - Added support for caching compilations that use precompiled headers. (See the
436   manual for important instructions regarding this.)
437
438 - Locking of the files containing statistics counters is now done using
439   symlinks instead of POSIX locks. This should make ccache behave a lot better
440   on file systems where POSIX locks are slow or broken (e.g. NFS on some
441   systems).
442
443 - Manifest files are now updated without the need of taking locks.
444
445 - Updates of statistics counters are now always done in one of the sub-level
446   statistics files. This reduces lock contention, which especially improves
447   performance on slow NFS mounts.
448
449 - Reading and writing of statistics counters has been made forward-compatible
450   (unknown counters are retained).
451
452 - Files are now read without using `mmap()`. This has two benefits: it's more
453   robust against file changes during reading and it improves performance on
454   poor systems where `mmap()` doesn't use the disk cache.
455
456 - Added `.cp` and `.CP` as known C++ suffixes.
457
458 - Improved logging.
459
460 - Added `-install_name` as an option known to take an argument. (This improves
461   statistics when using the Darwin linker.)
462
463
464 Bug fixes
465 ~~~~~~~~~
466
467 - Non-fatal error messages are now never printed to stderr but logged instead.
468
469 - Fixed a bug affecting failing commands when `--ccache-skip` is used.
470
471 - Made `--ccache-skip` work for all options.
472
473 - EINTR is now handled correctly.
474
475
476 Other
477 ~~~~~
478
479 - Work on porting ccache to win32 (native), mostly done by Ramiro Polla. The
480   port is not yet finished, but will hopefully be complete in some subsequent
481   release.
482
483 - Added a `--nostats` flag to the performance benchmark program.
484
485 - Made the performance benchmark program more accurate when measuring cache
486   hits.
487
488 - Added a new test framework for unit tests written in C.
489
490 - Got rid of `configure-dev`; dev mode is now given by `dev.mk.in` presence.
491
492 - Improved documentation on how to combine ccache with other compiler wrappers
493   (like `distcc`).
494
495 - New `LICENSE.txt` file with licensing and copyright details about bundled
496   source code.
497
498 - New `AUTHORS.txt` file with a list of ccache contributors.
499
500 - New `HACKING.txt` file with some notes about ccache code conventions.
501
502
503 ccache 3.0.1
504 ------------
505 Release date: 2010-07-15
506
507
508 Bug fixes
509 ~~~~~~~~~
510
511 - The statistics counter ``called for link'' is now correctly updated when
512   linking with a single object file.
513
514 - Fixed a problem with out-of-source builds.
515
516
517 ccache 3.0
518 ----------
519 Release date: 2010-06-20
520
521
522 General
523 ~~~~~~~
524
525 - ccache is now licensed under the GNU General Public License (GPL) version 3
526   or later.
527
528
529 Upgrade notes
530 ~~~~~~~~~~~~~
531
532 - The way the hashes are calculated has changed, so you won't get cache hits
533   for compilation results stored by older ccache versions. Because of this, you
534   might as well clear the old cache directory with `ccache --clear` if you
535   want, unless you plan to keep using an older ccache version.
536
537
538 New features and improvements
539 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
540
541 - ccache now has a ``direct mode'' where it computes a hash of the source code
542   (including all included files) and compiler options without running the
543   preprocessor. By not running the preprocessor, CPU usage is reduced; the
544   speed is somewhere between 1 and 5 times that of ccache running in
545   traditional mode, depending on the circumstances. The speedup will be higher
546   when I/O is fast (e.g., when files are in the disk cache). The direct mode
547   can be disabled by setting +CCACHE_NODIRECT+.
548
549 - Support has been added for rewriting absolute paths to relative paths when
550   hashing, in order to increase cache hit rate when building the same source
551   code in different directories even when compiling with `-g` and when using
552   absolute include directory paths. This is done by setting the
553   `CCACHE_BASEDIR` environment variable to an absolute path that specifies
554   which paths to rewrite.
555
556 - Object files are now optionally stored compressed in the cache. The runtime
557   cost is negligible, and more files will fit in the ccache directory and in
558   the disk cache. Set `CCACHE_COMPRESS` to enable object file compression. Note
559   that you can't use compression in combination with the hard link feature.
560
561 - A `CCACHE_COMPILERCHECK` option has been added. This option tells ccache what
562   compiler-identifying information to hash to ensure that results retrieved
563   from the cache are accurate. Possible values are: none (don't hash anything),
564   mtime (hash the compiler's mtime and size) and content (hash the content of
565   the compiler binary). The default is mtime.
566
567 - It is now possible to specify extra files whose contents should be included
568   in the hash sum by setting the `CCACHE_EXTRAFILES` option.
569
570 - Added support for Objective-C and Objective-C\+\+. The statistics counter
571   ``not a C/C++ file'' has been renamed to ``unsupported source language''.
572
573 - Added support for the `-x` compiler option.
574
575 - Added support for long command-line options.
576
577 - A `CACHEDIR.TAG` file is now created in the cache directory. See
578   <http://www.brynosaurus.com/cachedir/>.
579
580 - Messages printed to the debug log (specified by `CCACHE_LOGFILE`) have been
581   improved.
582
583 - You can relax some checks that ccache does in direct mode by setting
584   `CCACHE_SLOPPINESS`. See the manual for more information.
585
586 - `CCACHE_TEMPDIR` no longer needs to be on the same filesystem as
587   `CCACHE_DIR`.
588
589 - The default value of `CCACHE_TEMPDIR` has been changed to `$CCACHE_DIR/tmp`
590   to avoid cluttering the top directory.
591
592 - Temporary files that later will be moved into the cache are now created in
593   the cache directory they will end up in. This makes ccache more friendly to
594   Linux's directory layout.
595
596 - Improved the test suite and added tests for most of the new functionality.
597   It's now also possible to specify a subset of tests to run.
598
599 - Standard error output from the compiler is now only stored in the cache if
600   it's non-empty.
601
602 - If the compiler produces no object file or an empty object file, but gives a
603   zero exit status (could be due to a file system problem, a buggy program
604   specified by `CCACHE_PREFIX`, etc.), ccache copes with it properly.
605
606 - Added `installcheck` and `distcheck` make targets.
607
608 - Clarified cache size limit options' and cleanup semantics.
609
610 - Improved display of cache max size values.
611
612 - The following options are no longer hashed in the preprocessor mode:
613   `-imacros`, `-imultilib`, `-iprefix`, `-iquote`, `-isysroot`, `-iwithprefix`,
614   `-iwithprefixbefore`, `-nostdinc`, `-nostdinc++` and `-U`.
615
616
617 Bug fixes
618 ~~~~~~~~~
619
620 - Various portability improvements.
621
622 - Improved detection of home directory.
623
624 - User-defined `CPPFLAGS` and `LDFLAGS` are now respected in the Makefile.
625
626 - Fixed NFS issues.
627
628 - Computation of the hash sum has been improved to decrease the risk of hash
629   collisions. For instance, the compiler options `-X -Y` and `-X-Y` previously
630   contributed equally to the hash sum.
631
632 - Bail out on too hard compiler options `--coverage`, `-fprofile-arcs`,
633   `-fprofile-generate`, `-fprofile-use`, `-frepo`, `-ftest-coverage` and
634   `-save-temps`. Also bail out on `@file` style options.
635
636 - Errors when using multiple `-arch` compiler options are now noted as
637   ``unsupported compiler option''.
638
639 - `-MD`/`-MMD` options without `-MT`/`-MF` are now handled correctly.
640
641 - The `-finput-charset` option is now handled correctly.
642
643 - Added support for `-Wp,-MD` and `-Wp,-MMD` options.
644
645 - The compiler options `-Xassembler`, `-b`, `-G` and `-V` are now correctly
646   recognized as taking an argument.
647
648 - Debug information containing line numbers of predefined and command-line
649   macros (enabled with the compiler option `-g3`) will now be correct.
650
651 - Corrected LRU cleanup handling of object files.
652
653 - `utimes()` is now used instead of `utime()` when available.
654
655 - Non-writable cache directories are now handled gracefully.
656
657 - Corrected documentation about sharing the cache directory.
658
659 - Fixed compilation warnings from GCC 4.3.
660
661 - The command specified by `CCACHE_PREFIX` is no longer part of the hash.
662
663 - Fixed bad memory access spotted by Valgrind.
664
665 - Fixed a bug in `x_realloc`.
666
667 - Freed memory is no longer referenced when compiling a `.i`/`.ii` file and
668   falling back to running the real compiler.
669
670 - The test suite is now immune to external values of the `CCACHE_*` environment
671   variables.
672
673 - Improved detection of recursive invocation.
674
675 - The ccache binary is now not unconditionally stripped when installing.
676
677 - Statistics counters are now correctly updated for -E option failures and
678   internal errors.