mirror of
https://github.com/vlang/v.git
synced 2025-09-15 07:22:27 +03:00
compiler: cache modules
This commit is contained in:
parent
f45d3f07ed
commit
52f4f4026b
10 changed files with 422 additions and 242 deletions
|
@ -63,11 +63,12 @@ fn (v mut V) cc() {
|
|||
v.out_name = v.out_name + '.so'
|
||||
}
|
||||
if v.pref.build_mode == .build_module {
|
||||
// Create the modules directory if it's not there.
|
||||
if !os.file_exists(v_modules_path) {
|
||||
os.mkdir(v_modules_path)
|
||||
// Create the modules & out directory if it's not there.
|
||||
out_dir := v_modules_path + v.dir
|
||||
if !os.dir_exists(out_dir) {
|
||||
os.mkdir(out_dir)
|
||||
}
|
||||
v.out_name = v_modules_path + v.dir + '.o' //v.out_name
|
||||
v.out_name = '${out_dir}.o' //v.out_name
|
||||
println('Building ${v.out_name}...')
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue