Re: [CMake] Installing and Exporting for multiple configurations

2013-04-08 Thread Matthew Woehlke
On 2013-04-06 18:01, J Decker wrote: I see so the proper full path would be get_property( existing_outname TARGET ${target} PROPERTY OUTPUT_NAME ) if( NOT existing_outname ) set( existing_outname ${target} ) endif( NOT existing_outname ) D

Re: [CMake] Installing and Exporting for multiple configurations

2013-04-06 Thread J Decker
I see so the proper full path would be get_property( existing_outname TARGET ${target} PROPERTY OUTPUT_NAME ) if( NOT existing_outname ) set( existing_outname ${target} ) endif( NOT existing_outname ) DESTINATION lib${LIB_SUFFIX}/${CMAKE_{STATIC

Re: [CMake] Installing and Exporting for multiple configurations

2013-04-06 Thread Matthew Woehlke
On 2013-04-04 19:19, J Decker wrote: On Thu, Apr 4, 2013 at 2:25 PM, Matthew Woehlke wrote: On 2013-04-04 17:04, J Decker wrote: Also, you should install to 'lib${LIB_SUFFIX}', not 'lib'. This will allow you (and distros packaging your software) to set LIB_SUFFIX to separate arch-specific comp

Re: [CMake] Installing and Exporting for multiple configurations

2013-04-04 Thread J Decker
On Thu, Apr 4, 2013 at 2:25 PM, Matthew Woehlke wrote: > On 2013-04-04 17:04, J Decker wrote: > >> Also, you should install to 'lib${LIB_SUFFIX}', not 'lib'. This will allow >>> you (and distros packaging your software) to set LIB_SUFFIX to separate >>> arch-specific components of 32- and 64-bit

Re: [CMake] Installing and Exporting for multiple configurations

2013-04-04 Thread Matthew Woehlke
On 2013-04-04 17:04, J Decker wrote: Also, you should install to 'lib${LIB_SUFFIX}', not 'lib'. This will allow you (and distros packaging your software) to set LIB_SUFFIX to separate arch-specific components of 32- and 64-bit builds. E.g. on Linux, lib_suffix is usually ''/'64' or '32'/'', and o

Re: [CMake] Installing and Exporting for multiple configurations

2013-04-04 Thread J Decker
> Also, you should install to 'lib${LIB_SUFFIX}', not 'lib'. This will allow > you (and distros packaging your software) to set LIB_SUFFIX to separate > arch-specific components of 32- and 64-bit builds. E.g. on Linux, > lib_suffix is usually ''/'64' or '32'/'', and on Windows might be > ''/'/amd64

Re: [CMake] Installing and Exporting for multiple configurations

2013-04-04 Thread Saad Khattak
Thanks for the solution. I will try this but perhaps you are right and I should instead go with different builds for each configuration. On Thu, Apr 4, 2013 at 3:54 AM, J Decker wrote: > there is a variable that can be used... > > if( SUPPORTS_PARALLEL_BUILD_TYPE ) > INSTALL( lib/${CMAKE_

Re: [CMake] Installing and Exporting for multiple configurations

2013-04-04 Thread Matthew Woehlke
On 2013-04-03 22:06, Saad Khattak wrote: Hi, I am trying my best to understand CMake's install and export commands so that separate projects are able to find libraries easily. I am having a tremendously hard time understand what CMake is doing. After 'add_library()' where the library is called

Re: [CMake] Installing and Exporting for multiple configurations

2013-04-04 Thread J Decker
there is a variable that can be used... if( SUPPORTS_PARALLEL_BUILD_TYPE ) INSTALL( lib/${CMAKE_INSTALL_CONFIG_TYPE} ) would install into # used as install_mode_dest( target_names ) macro( install_mode_dest ) install( TARGETS ${ARGV} RUNTIME DESTINATION bin/\${CMAKE_INSTALL_CONFIG_NAME} LIB

[CMake] Installing and Exporting for multiple configurations

2013-04-03 Thread Saad Khattak
Hi, I am trying my best to understand CMake's install and export commands so that separate projects are able to find libraries easily. I am having a tremendously hard time understand what CMake is doing. After 'add_library()' where the library is called 'myLib' I called the following: install(TA