mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-12-01 12:31:37 +08:00
95937528f2
When enkiTS was built on windows with dynamic linking it would fail to install the dll. A dependent application would successfully link against the stub .lib and then fail to even get to `main` because the enkiTS dll was missing. I made sure to test this locally by having a project of mine depend on the version of this port from my fork :) - [X] Changes comply with the [maintainer guide](https://github.com/microsoft/vcpkg-docs/blob/main/vcpkg/contributing/maintainer-guide.md). - [X] SHA512s are updated for each updated download. - [X] The "supports" clause reflects platforms that may be fixed by this new version. - [X] Any fixed [CI baseline](https://github.com/microsoft/vcpkg/blob/master/scripts/ci.baseline.txt) entries are removed from that file. - [X] Any patches that are no longer applied are deleted from the port's directory. - [X] The version database is fixed by rerunning `./vcpkg x-add-version --all` and committing the result. - [X] Only one version is added to each modified port's versions file.
36 lines
1.2 KiB
Diff
36 lines
1.2 KiB
Diff
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
|
index 7f8572e..f42ec18 100644
|
|
--- a/CMakeLists.txt
|
|
+++ b/CMakeLists.txt
|
|
@@ -2,6 +2,8 @@ cmake_minimum_required(VERSION 3.0)
|
|
|
|
project( enkiTS )
|
|
|
|
+include(GNUInstallDirs)
|
|
+
|
|
option( ENKITS_BUILD_C_INTERFACE "Build C interface" ON )
|
|
option( ENKITS_BUILD_EXAMPLES "Build example applications" ON )
|
|
option( ENKITS_BUILD_SHARED "Build shared library" OFF )
|
|
@@ -59,9 +63,19 @@ if( UNIX )
|
|
target_link_libraries( enkiTS ${CMAKE_THREAD_LIBS_INIT} )
|
|
endif()
|
|
|
|
+target_include_directories(enkiTS PUBLIC "$<INSTALL_INTERFACE:include>")
|
|
if( ENKITS_INSTALL )
|
|
- install(TARGETS enkiTS DESTINATION "${CMAKE_INSTALL_PREFIX}/lib/enkiTS")
|
|
- install(FILES ${ENKITS_HEADERS} DESTINATION "${CMAKE_INSTALL_PREFIX}/include/enkiTS")
|
|
+ install(
|
|
+ TARGETS enkiTS
|
|
+ EXPORT enkiTS-config
|
|
+ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
|
|
+ LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
|
+ ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
|
+ install(FILES ${ENKITS_HEADERS} DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
|
|
+ install(
|
|
+ EXPORT enkiTS-config
|
|
+ NAMESPACE enkiTS::
|
|
+ DESTINATION ${CMAKE_INSTALL_DATADIR}/enkiTS)
|
|
endif()
|
|
|
|
if( UNIX )
|