[CMake] target path, or post build event?

KSpam keesling_spam at cox.net
Thu Oct 25 11:36:08 EDT 2007


Mark,

What do you have CMAKE_INSTALL_PREFIX set to?  My guess is that it defaults 
to "C:\Program Files\${PROJECT_NAME}".  I do not develop on Windows, so I 
cannot say for sure.  CMAKE_INSTALL_PREFIX is used to prefix the DESTINATION 
unless DESTINATION is specified as a full path.  Alternately, you can set 
DESTINATION to a full path.

Also, if cmaketest.exe is a target built by CMake, you might prefer to use:

INSTALL(TARGETS ${cmaketestTarget} DESTINATION ${dest})

Justin

On Thursday 25 October 2007 07:56:38 Mark Wyszomierski wrote:
> It seems to work, though is moving the file I want to copy into an
> unexpected location. Using the following:
>
> INSTALL(FILES debug/cmaketest.exe DESTINATION copy_file_test)
>
> I'm trying to move the file 'cmaketest.exe' located in a subdirectory
> called 'debug' into another subdirectory called 'copy_file_test'.
>
> The file actually gets copied to:
>
>     C:\Program Files\CMAKETEST\copy_file_test
>
> though. The name of my project is CMakeTest. Any idea?
>
> Thanks,
> Mark


More information about the CMake mailing list