[CMake] deploy VS2008 application

J Decker d3ck0r at gmail.com
Sat Aug 27 17:40:12 EDT 2011


This bit of code works well, skip the isntallation, so I can put them
where I want
if debug, only grab debug (otherwise you get msvcrtX and mvcrtXd )
the install (in this case in destination bin/<project mode>  which you
will probably want to change.


# get the libraries..
SET( CMAKE_INSTALL_SYSTEM_RUNTIME_LIBS_SKIP 1 )
if( ${CMAKE_BUILD_TYPE} MATCHES "[dD][eE][bB][uU][gG]" )
SET( CMAKE_INSTALL_DEBUG_LIBRARIES 1 )
SET( CMAKE_INSTALL_DEBUG_LIBRARIES_ONLY 1 )
endif( ${CMAKE_BUILD_TYPE} MATCHES "[dD][eE][bB][uU][gG]" )

INCLUDE(InstallRequiredSystemLibraries)
#message( "Resulting install: ${CMAKE_INSTALL_SYSTEM_RUNTIME_LIBS}" )
INSTALL( FILES ${CMAKE_INSTALL_SYSTEM_RUNTIME_LIBS} DESTINATION
bin/\${CMAKE_INSTALL_CONFIG_NAME} )


On Sat, Aug 27, 2011 at 2:32 PM, Yifei Li <yifli at mtu.edu> wrote:
> On Aug 27, 2011, at 4:52 PM, John Drescher wrote:
>
>>> The application I deployed is a DEBUG version and I have include(InstallRequiredSystemLibraries) in my CMakeLists.txt.
>>>
>>> However, msvc(m/p/r)90.dll instead of msvc(m/p/r)90d.dll are copied to the destination folder.  Any idea why this happened?
>>>
>>
>> Do you realize that it is a violation of your Visual Studio license to
>> deploy debug libraries?
>>
>> John
>
> No, I did not know that. I'm not developing any commercial software though.
>
> So it's impossible to use cmake to deploy debug vs libraries, is it?
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.cmake.org/mailman/listinfo/cmake
>


More information about the CMake mailing list