Alan W. Irwin wrote:
> On 2006-09-12 06:33+0200 Arjen Markus wrote:
>> The main thing that has changed is my modus operandi: use a separate
>> directory for building. This means a different part of the CMake
>> buidl system is invoked, but I can not see how that causes this
>> strange behaviour.
>> (Before I used the _same_ directory for Windows, and that succeeded)
> This is the key to the problem. A small amount of extra code is
> in the separate build tree case for -DBUILD_TEST=ON and
> -DENABLE_tcl=ON, and
> the problem occurs just for this code which involves add_custom_target
> the target includes an absolute path in the target name. Apparently that
> style does not work on windows although it does work on Linux.
Probably due to the single-tree approach for directories: on Windows the C:\
drive gets in the way.
> Arjen, I am really glad you exercised this specific (windows + tcl +
> separate build tree + BUILD_TEST) case. Otherwise, we would never have
> found the error until much later. Also, thanks, for making a detailed
> about this problem on the CMake list. Brad King came up with a possible
> solution there (a changed style) which I am sure is correct. Aren't those
> guys great?
Yes, they are! By putting our CBS to all these tests I am both learning
the CMake system.
> I just implemented and cvs committed his suggested change in style for
> examples/tcl/CMakeLists.txt. Does that new style solve your separate
> build-tree problems (with -DBUILD_TEST=ON and -DENABLE_tcl=ON) on
> It certainly works for those conditions on Linux.
> I have now checked all the examples, and only python has a similar
> add_custom_target with a target that includes the absolute path. I will
> change that also to the new style in anticipation that you and Werner
> soon be testing our python examples on windows. :-)
Step by step ... but it is rewarding.