Skip to content

Commit cb7047d

Browse files
committed
Link libc++ statically to reduce runtime dependency of wamrc
1 parent d39d2ba commit cb7047d

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

wamr-compiler/CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -387,6 +387,8 @@ if (NOT MSVC)
387387
target_link_libraries (wamrc ssp.a ws2_32)
388388
else()
389389
target_link_libraries (wamrc -ldl)
390+
# Link libc++ statically to reduce the runtime dependency
391+
target_link_libraries (wamrc -static-libstdc++)
390392
endif()
391393
else()
392394
target_link_libraries (wamrc aotclib vmlib ${lib_lldb} ${WAMRC_LINK_LLVM_LIBS} ${lib_ubsan}

0 commit comments

Comments
 (0)