mirror of
https://github.com/MaskRay/ccls.git
synced 2024-11-22 23:55:08 +00:00
[waf] Add -std=c++11 when CXXFLAGS is specified without -std= setting
This commit is contained in:
parent
5029173c8a
commit
fd264310c2
2
wscript
2
wscript
@ -137,6 +137,8 @@ def configure(ctx):
|
|||||||
# If environment variable CXXFLAGS is unset, provide a sane default.
|
# If environment variable CXXFLAGS is unset, provide a sane default.
|
||||||
if not ctx.env.CXXFLAGS:
|
if not ctx.env.CXXFLAGS:
|
||||||
ctx.env.CXXFLAGS = cxxflags
|
ctx.env.CXXFLAGS = cxxflags
|
||||||
|
elif all(not x.startswith('-std=') for x in ctx.env.CXXFLAGS):
|
||||||
|
ctx.env.CXXFLAGS.append('-std=c++11')
|
||||||
if not ctx.env.LDFLAGS:
|
if not ctx.env.LDFLAGS:
|
||||||
ctx.env.LDFLAGS = ldflags
|
ctx.env.LDFLAGS = ldflags
|
||||||
else:
|
else:
|
||||||
|
Loading…
Reference in New Issue
Block a user