mirror of
https://github.com/MaskRay/ccls.git
synced 2025-02-16 13:48:04 +00:00
[waf] Use str for Python 2
This commit is contained in:
parent
d573a68130
commit
2c787fe1fe
4
wscript
4
wscript
@ -238,9 +238,9 @@ def configure(ctx):
|
||||
# Use the detected clang executable to infer resource directory
|
||||
# Use `clang -### -xc /dev/null` instead of `clang -print-resource-dir` because the option is unavailable in 4.0.0
|
||||
devnull = '/dev/null' if sys.platform != 'win32' else 'NUL'
|
||||
output = subprocess.check_output(
|
||||
output = str(subprocess.check_output(
|
||||
[clang, '-###', '-xc', devnull],
|
||||
stderr=subprocess.STDOUT).decode()
|
||||
stderr=subprocess.STDOUT).decode())
|
||||
match = re.search(r'"-resource-dir" "([^"]*)"', output, re.M)
|
||||
if match:
|
||||
ctx.env.default_resource_directory = match.group(1)
|
||||
|
Loading…
Reference in New Issue
Block a user