[CMake] Cache option modification would require new libraries search

Olivier Pierard olivier.pierard at cenaero.be
Fri Nov 27 08:36:35 EST 2009


Dear all,

Two options in my project will influence the libraries/paths search: a
32/64 bits compilation switch and a static/shared third-party libraries
link switch.  These options are stored in the cache so that the user can
modify them.

Modifying one of these cache variable should obviously influence the
libraries search, which are also stored in the cache.  So:
0°) Is there a way to explain to cmake that one search is dependent on
given variables (or inter-dependence between cache variables)
1°) How can I detect that one of these two variable has been modified ?
2°) How can I reset automatically (e.g. setting them to NOTFOUND) all
libraries found during the first cmake run ?
3°) I would like to avoid to multiply libraries names by looking for the
four combinations of each library because I have already numerous ones
4°) Removing the libraries from the cache is not an option because the
user should have the possibility to modify them

Thanks for your help.  I have already noticed some similar discussions
on the web but without real answer...



More information about the CMake mailing list