diff options
author | kinichiro <kinichiro.inoguchi@gmail.com> | 2021-11-27 20:57:14 +0900 |
---|---|---|
committer | kinichiro <kinichiro.inoguchi@gmail.com> | 2021-11-27 20:57:14 +0900 |
commit | 870a1ebbc20324c3276842c494756e219801a738 (patch) | |
tree | dee8c7a02f9289f7120af4361c77a29614cb6b15 /tls | |
parent | 2ac3d32ec532b9e62efe20f3e7d03245cd2b09c3 (diff) | |
download | portable-870a1ebbc20324c3276842c494756e219801a738.tar.gz portable-870a1ebbc20324c3276842c494756e219801a738.tar.bz2 portable-870a1ebbc20324c3276842c494756e219801a738.zip |
Build static library for regression tests when shared build with CMake
Diffstat (limited to 'tls')
-rw-r--r-- | tls/CMakeLists.txt | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tls/CMakeLists.txt b/tls/CMakeLists.txt index 9aa10e1..17aedf0 100644 --- a/tls/CMakeLists.txt +++ b/tls/CMakeLists.txt | |||
@@ -74,3 +74,17 @@ if(ENABLE_LIBRESSL_INSTALL) | |||
74 | RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} | 74 | RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} |
75 | ) | 75 | ) |
76 | endif(ENABLE_LIBRESSL_INSTALL) | 76 | endif(ENABLE_LIBRESSL_INSTALL) |
77 | |||
78 | # build static library for regression test | ||
79 | if(BUILD_SHARED_LIBS) | ||
80 | add_library(tls-static STATIC $<TARGET_OBJECTS:tls_obj> | ||
81 | $<TARGET_OBJECTS:ssl_obj> $<TARGET_OBJECTS:crypto_obj>) | ||
82 | target_include_directories(tls-static | ||
83 | PRIVATE | ||
84 | . | ||
85 | ../include/compat | ||
86 | PUBLIC | ||
87 | ../include) | ||
88 | target_link_libraries(tls-static ${PLATFORM_LIBS}) | ||
89 | endif() | ||
90 | |||