2010/9/28 Marcel Loose <[email protected]>: >> >> You may want to call your target "help" but it would conflict/override >> the cmake builtin "help" target >> (at least for makefile generator) which display the list of available > target. >> >> This work AFTER cmake has been run. It could be run before as well > using: >> >> cmake -DCMAKE_MODULE_PATH=/path/to/source --help-module HelpMe >> >> but this is awkward :-( >> > Thanks Erk, > > I'll give it a thought. Your solution uses some nice CMake features, but > I find it a bit awkward. It suffers from separation of code and > documentation, though. That's always risky, since the two are likely to > diverge.
It is a little bit, but you can put in this "custom cmake file" (you may rename it to "CustomizableOptions.cmake") any CMake *code* you want including the definition of OPTION or vars (using SET) etc... then in you CMakeLists.txt you can include(CustomizableOptions.cmake) and the "header" of the file contains the useful doc. for the concerned option/vars. then the code and it's doc stay together. -- Erk Membre de l'April - « promouvoir et défendre le logiciel libre » - http://www.april.org _______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
