scripts: waifulib: compiler_optimizations: fix linking OpenMP
This commit is contained in:
parent
75a315ecf0
commit
103b9724f9
1 changed files with 6 additions and 0 deletions
|
@ -127,6 +127,11 @@ OPENMP_CFLAGS = {
|
||||||
'msvc': ['/openmp']
|
'msvc': ['/openmp']
|
||||||
}
|
}
|
||||||
|
|
||||||
|
OPENMP_LINKFLAGS = {
|
||||||
|
'gcc': ['-fopenmp'],
|
||||||
|
'clang': ['-fopenmp'],
|
||||||
|
}
|
||||||
|
|
||||||
PROFILE_GENERATE_CFLAGS = {
|
PROFILE_GENERATE_CFLAGS = {
|
||||||
'gcc': ['-fprofile-generate=xash3d-prof'],
|
'gcc': ['-fprofile-generate=xash3d-prof'],
|
||||||
}
|
}
|
||||||
|
@ -214,6 +219,7 @@ def get_optimization_flags(conf):
|
||||||
cflags += conf.get_flags_by_compiler(POLLY_CFLAGS, conf.env.COMPILER_CC)
|
cflags += conf.get_flags_by_compiler(POLLY_CFLAGS, conf.env.COMPILER_CC)
|
||||||
|
|
||||||
if conf.options.OPENMP:
|
if conf.options.OPENMP:
|
||||||
|
linkflags+= conf.get_flags_by_compiler(OPENMP_LINKFLAGS, conf.env.COMPILER_CC)
|
||||||
cflags += conf.get_flags_by_compiler(OPENMP_CFLAGS, conf.env.COMPILER_CC)
|
cflags += conf.get_flags_by_compiler(OPENMP_CFLAGS, conf.env.COMPILER_CC)
|
||||||
|
|
||||||
if conf.options.PROFILE_GENERATE:
|
if conf.options.PROFILE_GENERATE:
|
||||||
|
|
Loading…
Add table
Reference in a new issue