[Python-Dev] Evaluated cmake as an autoconf replacement (original) (raw)

David Cournapeau cournape at gmail.com
Wed Apr 8 04🔞16 CEST 2009


On Wed, Apr 8, 2009 at 7:54 AM, Alexander Neundorf <alex.neundorf at kitware.com> wrote:

On Wed, Apr 8, 2009 at 12:43 AM, Greg Ewing <greg.ewing at canterbury.ac.nz> wrote:

David Cournapeau wrote:

Having a full fledged language for complex builds is nice, I think most familiar with complex makefiles would agree with this. Yes, people will still need general computation in their build process from time to time whether the build tool they're using supports it or not. I'm maintaining the CMake-based buildsystem for KDE4 since 3 years now in my sparetime, millions lines of code, multiple code generators, all major operating systems. My experience is that people don't need general computation in their build process. CMake supports now more general purpose programming features than it did 2 years ago, e.g. it has now functions with local variables, it can do simple math, regexps and other things. If we get to the point where this is not enough, it usually means a real program which does real work is required. In this case it's actually a good thing to have this as a separate tool, and not mixed into the buildsystem. Having a not very powerful, but therefor domain specific language for the buildsystem is really a feature :-) (even if it sounds wrong in the first moment).

Yes, there are some advantages to that. The point of python is to have the same language for the build specification and the extensions, in my mind. For extensions, you really need a full language - for example, if you want to add support for tools which generate unknown files in advance, and handle this correctly from a build POV, a macro-like language is not sufficient.

>From what I saw when I was building Python I didn't actually see too complicated things. In KDE4 we are not only building and installing programs, but we are also installing and shipping a development platform. This includes CMake files which contain functionality which helps in developing KDE software, i.e. variables and a bunch of KDE-specific macros. They are documented here: http://api.kde.org/cmake/modules.html#moduleFindKDE4Internal (this is generated automatically from the cmake file we ship). I guess something similar could be useful for Python, maybe this is what distutils actually do ?

distutils does roughly everything that autotools does, and more:

cheers,

David



More information about the Python-Dev mailing list