[Cmake] out of source builds
Christopher Baus
christopher at baus.net
Mon Aug 16 20:54:40 EDT 2004
>> Trying to put all those commands in as a chain of custom build statements
>> seems overkill... so the ability to have a custom command run a
> You could write a program in C or C++ to do all these operations to
> generate the file instead of depending on programs like "sed" and "gawk"
> being installed on the machine and in the path. Then just run this
> single program as the custom command. If you add the executable as a
> dependency, then CMake will setup proper rules to make sure the
> generator executable is built before this custom rule is executed.
I know this thread is a bit old, but I had the same problem, and I decided
to write the script in python. It more cross platform than using bash or
a windows batch file. And no need to compile as in C.
More information about the Cmake
mailing list