CMakeCache.txt
David Faure
faure at kde.org
Mon Mar 27 12:53:38 CEST 2006
autoconf used to always generate and reuse a config.cache, and then they changed the default
so that the user had to specify --cache explicitely instead, presumably because many people
didn't find out that they had to remove their config.cache after installing a library or changing
whatever else on their system.
cmake seems to have the same problem; people don't find out about the need to
remove CMakeCache.txt if wrong things were detected. But I see how cmake needs
to always use a cache, since any change to a CMakeLists.txt triggers a re-configuration....
Suggestions/requests:
a) not writing out CMakeCache.txt until the configuration step succeeds (so that at least
during the initial attempt at configuring there is no need to remove it all the time).
b) a bigger change: separating CMakeConfigure.txt (name made up) from CMakeLists.txt
so that a trivial change to a CMakeLists (like adding a new source file) doesn't trigger a
re-configuration, only a change to CMakeConfigure.txt would do that.
And then it's possible to not write out a CMakeCache.txt at all unless the user asks for it,
since there will be less re-configuration happening.
--
David Faure, faure at kde.org, sponsored by Trolltech to work on KDE,
Konqueror (http://www.konqueror.org), and KOffice (http://www.koffice.org).
More information about the Kde-buildsystem
mailing list