Commit 889c6f19 authored by da-woods's avatar da-woods Committed by Stefan Behnel

Change gcc version check in test runner to a numeric comparison (GH-4359)

The string comparison was reporting '11' < '4' (so OpenMP tests were being skipped on GCC 11)
parent ff712a90
......@@ -362,7 +362,9 @@ def get_openmp_compiler_flags(language):
COMPILER_HAS_INT128 = getattr(sys, 'maxsize', getattr(sys, 'maxint', 0)) > 2**60
compiler_version = gcc_version.group(1)
if compiler_version and compiler_version.split('.') >= ['4', '2']:
if compiler_version:
compiler_version = [int(num) for num in compiler_version.split('.')]
if compiler_version >= [4, 2]:
return '-fopenmp', '-fopenmp'
try:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment