13
0

remove more explicit compiler flags by placing them in the compiler flags dictionary

This commit is contained in:
Paul Davis 2015-05-13 22:20:38 -04:00
parent 3adfa9ef57
commit 6485300479
2 changed files with 6 additions and 3 deletions

View File

@ -88,10 +88,10 @@ def build(bld):
obj.use = 'libardour libpbd'
if bld.env['build_target'] == 'mingw':
obj.uselib = ['PORTAUDIO']
obj.cxxflags = [ '-fPIC' ]
obj.cflags = [ '-fPIC', '-fms-extensions' ]
obj.cxxflags = [ bld.env['compiler_flags_dict']['pic'] ]
obj.cflags = [ bld.env['compiler_flags_dict']['pic'], bld.env['compiler_flags_dict']['c-anonymous-union'] ]
else:
obj.cflags = ['-fms-extensions' ]
obj.cflags = [ bld.env['compiler_flags_dict']['c-anonymous-union'] ]
obj.install_path = os.path.join(bld.env['LIBDIR'], 'backends')
if bld.env['build_target']== 'mingw':

View File

@ -82,6 +82,8 @@ compiler_flags_dictionaries= {
'avx': '-mavx',
# Flags to generate position independent code, when needed to build a shared object
'pic': '-fPIC',
# Flags required to compile C code with anonymous unions (only part of C11)
'c-anonymous-union': '-fms-extensions',
},
'msvc' : {
'debuggable' : ['/DDEBUG', '/Od', '/Zi', '/MDd', '/Gd', '/EHsc'],
@ -112,6 +114,7 @@ compiler_flags_dictionaries= {
'attasm': '',
'avx': '',
'pic': '',
'c-anonymous-union': '',
},
}