Skip to content

Commit

Permalink
Set -O2 compiler flag by default for gcc
Browse files Browse the repository at this point in the history
But only if no other optimization flags could be found.
  • Loading branch information
eht16 committed Oct 26, 2014
1 parent c35dedf commit a7a893a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions wscript
Expand Up @@ -302,6 +302,8 @@ but you then may not have a local copy of the HTML manual.'''

# some more compiler flags
conf.env.append_value('CFLAGS', ['-DHAVE_CONFIG_H'])
if conf.env['CC_NAME'] == 'gcc' and '-O' not in ''.join(conf.env['CFLAGS']):
conf.env.append_value('CFLAGS', ['-O2'])
if revision is not None:
conf.env.append_value('CFLAGS', ['-g', '-DGEANY_DEBUG'])
# Scintilla flags
Expand Down

0 comments on commit a7a893a

Please sign in to comment.