[CMake] Question about install()

Robert Dailey rcdailey at gmail.com
Wed Dec 10 11:17:19 EST 2008


On Wed, Dec 10, 2008 at 8:23 AM, David Cole <david.cole at kitware.com> wrote:

> On Tue, Dec 9, 2008 at 9:18 PM, Bill Hoffman <bill.hoffman at kitware.com>wrote:
>
>> ....... If you did not want to use python, you could use cmake
>> -DCONFIG=${CMAKE_CFG_INTDIR} -E myscript.cmake    .......
>>
>
> Make that:
> cmake -DCONFIG=${CMAKE_CFG_INTDIR} -P myscript.cmake
>
> -P for *p*rocess script, not -E
>

Thanks for the help everybody, I really appreciate it! These DLL files are
*not* built by CMake. They are third party libraries built elsewhere (On a
different windows machine, even). I'm a bit skeptical to put the copy logic
in Python because it only makes our build system more complex. People who
know CMake now have to learn Python in order to work with our build system.

The reason why I was passing in the configuration name itself and not the
INTDIR is because I would be doing string compares on the configuration name
itself to decide what libraries to copy over. A psuedo code example of what
I'm talking about follows:

if configuration == "debug" then
  copy "foo_d.dll" to INTDIR
  copy "bar_d.dll" to INTDIR
else if configuration == "release" then
  copy "foo.dll" to INTDIR
  copy "bar.dll" to INTDIR
end if

Note that in both the 'debug' and 'release' cases, the INTDIR will properly
reflect the "debug" executable directory and the "release" executable
directory, respectively.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20081210/d8bfe960/attachment.htm>


More information about the CMake mailing list