On Nov 26, 2007 6:03 PM, Pau Garcia i Quiles <[EMAIL PROTECTED]> wrote: > > Before Lua is added as a language to CMake, I'd like to ask a > question: is there really a need for Lua (or any other language) or is > the current CMake scripting Turing-complete and able to do anything > which could be done with Lua?
That's a false dichotomy. Turing Completeness doesn't say anything about whether a language is a PITA. To me there are 2 questions. (1) is there anything seriously objectionable about CMake script as it stands now? (2) is it better to improve CMake script itself, or to embed a 2nd language that doesn't have the problem? Many of us agree that lack of scope for variables is a problem. However, when we last spoke, acceptable solutions seemed to be possible within CMake itself. A question is, how long will they take, vs. embedding a language which doesn't have a scoping problem? I think CMake's regular expressions are quite a bit less than ideal. Adding the Perl Compatible Regular Expressions library to CMake is certainly possible. It would be a certain amount of work, and I've wondered if the work would be worth it to me personally. If CMake adopts Lua for other reasons, I can get Posix and PCRE regexes for free, as people have already implemented wrappers for them. Lua's core syntax has better regexes than CMake in some respects, but it's missing the branch "|" operator. I'm not sure whether I'd find Lua's regexes adequate in practice; it would be a contest between the "better" and the missing features. CMake's documentation, as mentioned, is objectionable. It's getting better, but we need definitive ways for people to learn quoting and escape behavior, list vs. string types, etc. "Chapter oriented" material. Documentation in CVS is getting better, a new version of "Mastering CMake" will be available in early 2008, and we're perfectly capable of revamping the wiki if we have the energy. A new language such as Lua, however, has a lot of documentation "for free" that we'll never have to maintain. Lua is a sufficiently popular language that it can attract people to CMake simply because Lua is being used. It is perceived as a "fast" scripting language. When I think about converting people and gaining the "ultimate masses" of CMake users that we will one day have, I think Lua has a lot more strategic marketing power than CMake's Yet Another Scripting Language. Just as experienced CMake users are currently objecting to having to deal with another language, the rest of the world objects to having to learn CMake script. And at present, I think there are a lot more techies who don't use CMake than do use CMake. At present I'm open to the possibility of Lua. I don't have to have it. Everything on my list of objections could be solved by improving CMake script. I think there are valid reasons to investigate Lua. Cheers, Brandon Van Every _______________________________________________ CMake mailing list [email protected] http://www.cmake.org/mailman/listinfo/cmake
