4 def is_gold_v1_12_linker_available():
6 if not config.gold_executable:
9 ld_cmd = subprocess.Popen([config.gold_executable, '-v'],
10 stdout = subprocess.PIPE,
11 stderr = subprocess.PIPE)
12 ld_out, _ = ld_cmd.communicate()
13 ld_out = ld_out.decode()
17 match = re.search(r'GNU gold \(.*\) (\d+)\.(\d+)', ld_out)
20 major = int(match.group(1))
21 minor = int(match.group(2))
22 if major < 1 or (major == 1 and minor < 12):
27 if not is_gold_v1_12_linker_available():
28 config.unsupported = True