Require at least Python 3.6.
gcc/testsuite/ChangeLog:
* gcc.src/maintainers.exp: Use the new
check_effective_target_recent_python3.
* lib/target-supports.exp: Check for Python3 version >= 3.6.
set contrib $rootdir/contrib
set maintainers $rootdir/MAINTAINERS
- if { ![check_effective_target_python3] } {
- unsupported "$script python3 is missing"
+ if { ![check_effective_target_recent_python3] } {
+ unsupported "$script recent python3 is missing"
return
}
} [current_compiler_flags]]
}
-# Return 1 if python3 is available.
+# Return 1 if python3 (>= 3.6) is available.
-proc check_effective_target_python3 { } {
- set result [remote_exec host "python3 --version"]
+proc check_effective_target_recent_python3 { } {
+ set result [remote_exec host "python3 -c \"import sys; assert sys.version_info >= (3, 6)\""]
set status [lindex $result 0]
if { $status == 0 } then {
return 1;