Skip to content

Commit

Permalink
fix BUILD_VOICE_SUPPORT=OFF static build
Browse files Browse the repository at this point in the history
  • Loading branch information
Syping authored Nov 27, 2024
1 parent aedc1a9 commit 2f670df
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions library/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -411,17 +411,20 @@ if(DPP_FORMATTERS)
endif()

if (NOT BUILD_SHARED_LIBS)
add_library(dppstatic STATIC
if (HAVE_VOICE)
add_library(dppstatic STATIC
$<TARGET_OBJECTS:dpp>
$<TARGET_OBJECTS:hpke>
$<TARGET_OBJECTS:tls_syntax>
$<TARGET_OBJECTS:mls_vectors>
$<TARGET_OBJECTS:mlspp>
$<TARGET_OBJECTS:bytes>
)
if (HAVE_VOICE)
)
target_link_libraries(dppstatic ${ZLIB_LIBRARIES} ${OPENSSL_LIBRARIES} ${OPUS_LIBRARIES} -static-libgcc -static-libstdc++)
else()
add_library(dppstatic STATIC
$<TARGET_OBJECTS:dpp>
)
target_link_libraries(dppstatic ${ZLIB_LIBRARIES} ${OPENSSL_LIBRARIES})
endif()
endif()
Expand Down

0 comments on commit 2f670df

Please sign in to comment.