v/cmd/tools/vsetup-freetype.v

29 lines
576 B
V
Raw Normal View History

2020-02-24 18:01:35 +01:00
module main
import (
os
v.pref
)
fn main() {
$if windows {
println('Setup freetype...')
2020-03-07 22:26:26 +01:00
vroot := os.dir(pref.vexe_path())
2020-02-24 18:01:35 +01:00
os.chdir(vroot)
if os.is_dir('./thirdparty/freetype') {
println('Thirdparty "freetype" is already installed.')
}
else {
s := os.exec('git clone --depth=1 https://github.com/ubawurinna/freetype-windows-binaries ./thirdparty/freetype/') or {
panic(err)
}
println(s.output)
println('Thirdparty "freetype" installed successfully.')
}
}
$else {
println('It is only for Windows to setup thirdparty "freetype".')
}
}