Allow to build LLVM and wamrc on MinGW (#1013)
Use sysconfig.get_platform() to check whether the platform is MinGW, and link necessary libraries to wamrc on MinGW.
This commit is contained in:
@ -250,6 +250,9 @@ add_executable (wamrc main.c)
|
||||
if (NOT MSVC)
|
||||
target_link_libraries (wamrc aotclib vmlib LLVMDemangle ${LLVM_AVAILABLE_LIBS} ${lib_ubsan}
|
||||
-lm -ldl -lpthread ${lib_lldb})
|
||||
if (MINGW)
|
||||
target_link_libraries (wamrc -lssp -lWs2_32)
|
||||
endif()
|
||||
else()
|
||||
target_link_libraries (wamrc aotclib vmlib ${lib_lldb} ${LLVM_AVAILABLE_LIBS} ${lib_ubsan})
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user