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

builder: fix support for tcc on windows (openlibm.o)

This commit is contained in:
Delyan Angelov 2020-10-25 03:35:28 +03:00
parent 4653ed3fa5
commit 5cb31c2c8f

View File

@ -785,6 +785,14 @@ fn (mut v Builder) build_thirdparty_obj_file(path string, moduleflags []cflag.CF
if os.exists(opath) {
return
}
if os.exists(obj_path) {
// Some .o files are distributed with no source
// for example thirdparty\tcc\lib\openlibm.o
// the best we can do for them is just copy them,
// and hope that they work with any compiler...
os.cp(obj_path, opath)
return
}
println('$obj_path not found, building it in $opath ...')
cfile := '${path[..path.len - 2]}.c'
btarget := moduleflags.c_options_before_target()