Re: [CMake] How to do that w/o LOCATION property of a target...

2015-09-05 Thread Gregor Jasny via CMake
On 05/09/15 08:22, Alex Turbov wrote: > Hi, > > in my project I have `add_executable()`. after that, in a current binary > dir I need to render a `*.cmake` script (via `configure_file()`) to be > running from `add_test()` (as `cmake -P`) which should start just the > compiled executable via `execu

Re: [CMake] How to do that w/o LOCATION property of a target...

2015-09-05 Thread Petr Kmoch
Hi Alex. I don't know if there is a better solution, but the following workaround should work for you: In your normal CMakeList, do `file(GENERATE OUTPUT location.cmake CONTENT "set(TheLocation \"$\")\n")`. Then, in the configured *.cmake script, do `include(location.cmake)`. The location of the

[CMake] How to do that w/o LOCATION property of a target...

2015-09-04 Thread Alex Turbov
Hi, in my project I have `add_executable()`. after that, in a current binary dir I need to render a `*.cmake` script (via `configure_file()`) to be running from `add_test()` (as `cmake -P`) which should start just the compiled executable via `execute_process()` and capture its output (to be proces