vcpkg/ports/check/linkage.patch
Kai Pastor 4ff2d52566
[check,libsbml] Update, port fixes (#34656)
* [libsbml] Update, port fixes

* [check] Follow VCPKG_LIBRARY_LINKAGE

* [check] Don't install checkmk

* [check] Burn-in dllimport

* [libsbml] Devendor dirent

* [libsbml] Burn-in library linkage

* Finish

* Fix typo

* [libsbml] Shorten patch
2023-10-24 09:09:15 -07:00

21 lines
651 B
Diff

diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 4a02dbe..3e147e4 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -188,7 +188,14 @@ target_include_directories(checkShared
)
if(NOT THIS_IS_SUBPROJECT)
- install(TARGETS check checkShared
+ if(BUILD_SHARED_LIBS)
+ set(lib checkShared)
+ set_target_properties(check PROPERTIES EXCLUDE_FROM_ALL 1)
+ else()
+ set(lib check)
+ set_target_properties(checkShared PROPERTIES EXCLUDE_FROM_ALL 1)
+ endif()
+ install(TARGETS ${lib}
EXPORT check-targets
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/manual-link