CMake Config and Version exports (#22)

This commit is contained in:
JosiahWI
2021-04-13 14:08:16 -05:00
committed by GitHub
parent aa294a8107
commit 9840eeabe8
3 changed files with 48 additions and 15 deletions

View File

@ -394,16 +394,10 @@ add_library(IrrlichtMt
)
set_target_properties(IrrlichtMt PROPERTIES
VERSION ${VERSION}
SOVERSION ${IRRLICHT_VERSION_MAJOR}.${IRRLICHT_VERSION_MINOR}
VERSION ${PROJECT_VERSION}
SOVERSION ${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}
)
if(WIN32)
set_target_properties(IrrlichtMt PROPERTIES PREFIX "") # for DLL name
endif()
# Installation
include(GNUInstallDirs)
install(TARGETS IrrlichtMt DESTINATION "${CMAKE_INSTALL_LIBDIR}")
install(DIRECTORY "${CMAKE_SOURCE_DIR}/include/" DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/irrlichtmt")