Unable to link C runtime library (libcmt.lib) using lld-link.exe (Windows)
问题 I'm writing a language using LLVM. I'd like to avoid having to package clang and simply use the LLVM tools (ex. lld, lld-link). I've been trying to invoke the printf function from my simple IR code ( testinput.ll ): ; ModuleID = 'Test2' source_filename = "entry" @str_0 = private unnamed_addr constant [13 x i8] c"Hello world!\00" declare i32 @printf(i8*, ...) define i32 @main() { entry: %anonymous_10 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @str_0, i32 0,