1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

fix cc_windows_cross()

This commit is contained in:
Alexander Medvednikov 2019-07-01 17:23:30 +02:00
parent 24b0fd5097
commit 6ddc57c190

View File

@ -424,7 +424,7 @@ fn (c &V) cc_windows_cross() {
} }
} }
mut libs := '' mut libs := ''
if c.pref.build_mode == DEFAULT_MODE { if c.pref.build_mode == default_mode {
libs = '$TmpPath/vlib/builtin.o' libs = '$TmpPath/vlib/builtin.o'
if !os.file_exists(libs) { if !os.file_exists(libs) {
println('`builtin.o` not found') println('`builtin.o` not found')
@ -462,7 +462,7 @@ fn (c &V) cc_windows_cross() {
println('Cross compilation for Windows failed. Make sure you have clang installed.') println('Cross compilation for Windows failed. Make sure you have clang installed.')
exit(1) exit(1)
} }
if c.pref.build_mode != BUILD { if c.pref.build_mode != build {
link_cmd := 'lld-link $obj_name $winroot/lib/libcmt.lib ' + link_cmd := 'lld-link $obj_name $winroot/lib/libcmt.lib ' +
'$winroot/lib/libucrt.lib $winroot/lib/kernel32.lib $winroot/lib/libvcruntime.lib ' + '$winroot/lib/libucrt.lib $winroot/lib/kernel32.lib $winroot/lib/libvcruntime.lib ' +
'$winroot/lib/uuid.lib' '$winroot/lib/uuid.lib'