diff --git a/cmake/install.cmake b/cmake/install.cmake index 6249af093..0c249b6cd 100644 --- a/cmake/install.cmake +++ b/cmake/install.cmake @@ -174,6 +174,7 @@ MACRO(SD_INSTALL_FILES) # In order to run xmlversion.exe in the build tree (see below), under Windows, # we nearly always have to copy all dependencies next to it (tgf, txml or Expat, SDL, compiler run-time). GET_TARGET_PROPERTY(TGF_LIB tgf LOCATION) + GET_TARGET_PROPERTY(PORTABILITY_LIB portability LOCATION) IF(NOT OPTION_3RDPARTY_EXPAT) GET_TARGET_PROPERTY(TXML_LIB txml LOCATION) ELSE(NOT OPTION_3RDPARTY_EXPAT) @@ -219,6 +220,11 @@ MACRO(SD_INSTALL_FILES) STRING(REPLACE \"$(ConfigurationName)\" \"\${CMAKE_INSTALL_CONFIG_NAME}\" TGF_LIB \${TGF_LIB}) STRING(REPLACE \"$(Configuration)\" \"\${CMAKE_INSTALL_CONFIG_NAME}\" TGF_LIB \${TGF_LIB}) LIST(APPEND _LIBS_TO_INSTALL \${TGF_LIB}) + SET(PORTABILITY_LIB ${PORTABILITY_LIB}) + STRING(REPLACE \"$(OutDir)\" \"\${CMAKE_INSTALL_CONFIG_NAME}\" PORTABILITY_LIB \${PORTABILITY_LIB}) + STRING(REPLACE \"$(ConfigurationName)\" \"\${CMAKE_INSTALL_CONFIG_NAME}\" PORTABILITY_LIB \${PORTABILITY_LIB}) + STRING(REPLACE \"$(Configuration)\" \"\${CMAKE_INSTALL_CONFIG_NAME}\" PORTABILITY_LIB \${PORTABILITY_LIB}) + LIST(APPEND _LIBS_TO_INSTALL \${PORTABILITY_LIB}) GET_FILENAME_COMPONENT(XMLVERSION_DIR \"\${XMLVERSION_EXE}\" PATH) MESSAGE(STATUS \"xmlversion : Libs to install=\${_LIBS_TO_INSTALL}\") FILE(INSTALL DESTINATION \"\${XMLVERSION_DIR}\" TYPE FILE FILES \${_LIBS_TO_INSTALL}) @@ -245,6 +251,7 @@ MACRO(SD_INSTALL_FILES) IF(NOT OPTION_3RDPARTY_EXPAT) LIST(APPEND _LIBS_TO_INSTALL \"${TXML_LIB}\") ENDIF(NOT OPTION_3RDPARTY_EXPAT) + LIST(APPEND _LIBS_TO_INSTALL \"${PORTABILITY_LIB}\") # CMake configuration for MSYS Makefiles generator assumes that 3rd party dependencies are installed # in standard Linux folders, hence in the PATH ; so no need to install next to xmlversion exe. IF(NOT CMAKE_GENERATOR STREQUAL \"MSYS Makefiles\") @@ -394,6 +401,7 @@ MACRO(SD_INSTALL_DIRECTORIES) # In order to run xmlversion.exe in the build tree (see below), under Windows, # we nearly always have to copy all dependencies next to it (tgf, txml or Expat, SDL, compiler run-time). GET_TARGET_PROPERTY(TGF_LIB tgf LOCATION) + GET_TARGET_PROPERTY(PORTABILITY_LIB portability LOCATION) IF(NOT OPTION_3RDPARTY_EXPAT) GET_TARGET_PROPERTY(TXML_LIB txml LOCATION) ELSE(NOT OPTION_3RDPARTY_EXPAT) @@ -442,6 +450,11 @@ MACRO(SD_INSTALL_DIRECTORIES) STRING(REPLACE \"$(ConfigurationName)\" \"\${CMAKE_INSTALL_CONFIG_NAME}\" TGF_LIB \${TGF_LIB}) STRING(REPLACE \"$(Configuration)\" \"\${CMAKE_INSTALL_CONFIG_NAME}\" TGF_LIB \${TGF_LIB}) LIST(APPEND _LIBS_TO_INSTALL \"\${TGF_LIB}\") + SET(PORTABILITY_LIB ${PORTABILITY_LIB}) + STRING(REPLACE \"$(OutDir)\" \"\${CMAKE_INSTALL_CONFIG_NAME}\" PORTABILITY_LIB \${PORTABILITY_LIB}) + STRING(REPLACE \"$(ConfigurationName)\" \"\${CMAKE_INSTALL_CONFIG_NAME}\" PORTABILITY_LIB \${PORTABILITY_LIB}) + STRING(REPLACE \"$(Configuration)\" \"\${CMAKE_INSTALL_CONFIG_NAME}\" PORTABILITY_LIB \${PORTABILITY_LIB}) + LIST(APPEND _LIBS_TO_INSTALL \"\${PORTABILITY_LIB}\") MESSAGE(STATUS \"xmlversion : Libs to install=\${_LIBS_TO_INSTALL}\") GET_FILENAME_COMPONENT(XMLVERSION_DIR \"\${XMLVERSION_EXE}\" PATH) FILE(INSTALL DESTINATION \"\${XMLVERSION_DIR}\" TYPE FILE FILES \${_LIBS_TO_INSTALL}) @@ -472,6 +485,7 @@ MACRO(SD_INSTALL_DIRECTORIES) SET(MINGW ${MINGW}) IF(MINGW) SET(_LIBS_TO_INSTALL \"${TGF_LIB}\") + LIST(APPEND _LIBS_TO_INSTALL \${PORTABILITY_LIB}) SET(OPTION_3RDPARTY_EXPAT ${OPTION_3RDPARTY_EXPAT}) IF(NOT OPTION_3RDPARTY_EXPAT) LIST(APPEND _LIBS_TO_INSTALL \"${TXML_LIB}\")