mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
linux: use gcc if tcc fails
This commit is contained in:
parent
be0830b24f
commit
090e1a87b7
@ -221,6 +221,8 @@ fn (v mut V) cc() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
args := a.join(' ')
|
args := a.join(' ')
|
||||||
|
start:
|
||||||
|
777 // TODO remove
|
||||||
cmd := '${v.pref.ccompiler} $args'
|
cmd := '${v.pref.ccompiler} $args'
|
||||||
// Run
|
// Run
|
||||||
if v.pref.show_c_cmd || v.pref.is_verbose {
|
if v.pref.show_c_cmd || v.pref.is_verbose {
|
||||||
@ -239,6 +241,13 @@ fn (v mut V) cc() {
|
|||||||
'-----------------------------------------------------------\n' +
|
'-----------------------------------------------------------\n' +
|
||||||
'Probably your C compiler is missing. \n' +
|
'Probably your C compiler is missing. \n' +
|
||||||
'Please reinstall it, or make it available in your PATH.')
|
'Please reinstall it, or make it available in your PATH.')
|
||||||
|
// TCC problems on linux? Try gcc
|
||||||
|
$if linux {
|
||||||
|
if v.pref.ccompiler == 'tcc' {
|
||||||
|
v.pref.ccompiler = 'cc'
|
||||||
|
goto start
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if v.pref.is_debug {
|
if v.pref.is_debug {
|
||||||
|
Loading…
Reference in New Issue
Block a user