I'm trying to include legacy Visual Studio projects into a cmake generated
solution like this:

project(Crypto)

include_external_msproject(${PROJECT_NAME}_vcproj
   "${CMAKE_CURRENT_SOURCE_DIR}/${PROJECT_NAME}_vs90.vcproj"
)

# add_dependencies(${PROJECT_NAME}_vcproj
# )

add_library(${PROJECT_NAME} INTERFACE)

target_link_libraries(${PROJECT_NAME} INTERFACE
   debug ${LIB_PATH_DEBUG}/${PROJECT_NAME}.lib 
   optimized ${LIB_PATH_RELEASE}/${PROJECT_NAME}.lib
)

add_dependencies(${PROJECT_NAME}
   ${PROJECT_NAME}_vcproj
)

This works only as long as the vcproj-files contain a configuration named
'release' and 'debug', but when they don't it seems there is no way to map
the existing configuration names (as also requested in
https://cmake.org/pipermail/cmake/2010-April/036388.html). I tried the
proposed way with imported targets, but I didn't succeed.

How can I map a configuration of an external ms-project (e.g.
'release_shared') into a configuration (e.g. 'release') of the
cmake-generated solution? The problem is that simply adding a configuration
named 'release' works, of course, but then I'd have to change the external
vcproj...




-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Reply via email to