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 /ssl | |
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 'ssl')
-rw-r--r-- | ssl/CMakeLists.txt | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/ssl/CMakeLists.txt b/ssl/CMakeLists.txt index a8e0a25..e4a3d95 100644 --- a/ssl/CMakeLists.txt +++ b/ssl/CMakeLists.txt | |||
@@ -89,3 +89,16 @@ if(ENABLE_LIBRESSL_INSTALL) | |||
89 | RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} | 89 | RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} |
90 | ) | 90 | ) |
91 | endif(ENABLE_LIBRESSL_INSTALL) | 91 | endif(ENABLE_LIBRESSL_INSTALL) |
92 | |||
93 | # build static library for regression test | ||
94 | if(BUILD_SHARED_LIBS) | ||
95 | add_library(ssl-static STATIC $<TARGET_OBJECTS:ssl_obj>) | ||
96 | target_include_directories(ssl-static | ||
97 | PRIVATE | ||
98 | . | ||
99 | ../include/compat | ||
100 | PUBLIC | ||
101 | ../include) | ||
102 | target_link_libraries(ssl-static crypto-static ${PLATFORM_LIBS}) | ||
103 | endif() | ||
104 | |||