Fix OpenThreads install on MSVC without a prefix

All this change does is make the install config for OpenThreads identical to the one in ModuleInstall.cmake
This commit is contained in:
Alexander "Ananace" Olofsson 2021-06-10 17:12:50 +02:00 committed by Robert Osfield
parent 51924943e2
commit b7fa2d7914

View File

@ -59,6 +59,9 @@ INSTALL(
IF(MSVC AND DYNAMIC_OPENSCENEGRAPH) IF(MSVC AND DYNAMIC_OPENSCENEGRAPH)
GET_TARGET_PROPERTY(PREFIX ${LIB_NAME} PREFIX) GET_TARGET_PROPERTY(PREFIX ${LIB_NAME} PREFIX)
IF("${PREFIX}" STREQUAL PREFIX-NOTFOUND) # Fix for PREFIX-NOTFOUND left in file names
SET(PREFIX "")
ENDIF()
IF( ${CMAKE_GENERATOR} STREQUAL "Ninja" ) IF( ${CMAKE_GENERATOR} STREQUAL "Ninja" )
INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/${PREFIX}${LIB_NAME}${CMAKE_RELEASE_POSTFIX}.pdb DESTINATION ${INSTALL_BINDIR} COMPONENT libopenthreads CONFIGURATIONS Release) INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/${PREFIX}${LIB_NAME}${CMAKE_RELEASE_POSTFIX}.pdb DESTINATION ${INSTALL_BINDIR} COMPONENT libopenthreads CONFIGURATIONS Release)
INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/${PREFIX}${LIB_NAME}${CMAKE_RELWITHDEBINFO_POSTFIX}.pdb DESTINATION ${INSTALL_BINDIR} COMPONENT libopenthreads CONFIGURATIONS RelWithDebInfo) INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/${PREFIX}${LIB_NAME}${CMAKE_RELWITHDEBINFO_POSTFIX}.pdb DESTINATION ${INSTALL_BINDIR} COMPONENT libopenthreads CONFIGURATIONS RelWithDebInfo)