Skip to content

Commit

Permalink
Link libc++ statically to reduce runtime dependency of wamrc
Browse files Browse the repository at this point in the history
  • Loading branch information
no1wudi committed Apr 18, 2024
1 parent d39d2ba commit cb7047d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions wamr-compiler/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -387,6 +387,8 @@ if (NOT MSVC)
target_link_libraries (wamrc ssp.a ws2_32)
else()
target_link_libraries (wamrc -ldl)
# Link libc++ statically to reduce the runtime dependency
target_link_libraries (wamrc -static-libstdc++)
endif()
else()
target_link_libraries (wamrc aotclib vmlib ${lib_lldb} ${WAMRC_LINK_LLVM_LIBS} ${lib_ubsan}
Expand Down

0 comments on commit cb7047d

Please sign in to comment.