diff options
Diffstat (limited to 'platform')
-rw-r--r-- | platform/windows/detect.py | 5 | ||||
-rw-r--r-- | platform/x11/detect.py | 5 |
2 files changed, 8 insertions, 2 deletions
diff --git a/platform/windows/detect.py b/platform/windows/detect.py index 92f2e078c8..031b397988 100644 --- a/platform/windows/detect.py +++ b/platform/windows/detect.py @@ -265,7 +265,10 @@ def configure(env): if env['use_lto']: env.Append(CCFLAGS=['-flto']) - env.Append(LINKFLAGS=['-flto']) + if not env['use_llvm'] and env.GetOption("num_jobs") > 1: + env.Append(LINKFLAGS=['-flto=' + str(env.GetOption("num_jobs"))]) + else: + env.Append(LINKFLAGS=['-flto']) ## Compile flags diff --git a/platform/x11/detect.py b/platform/x11/detect.py index c8d9930af1..1f7f67fe10 100644 --- a/platform/x11/detect.py +++ b/platform/x11/detect.py @@ -120,7 +120,10 @@ def configure(env): if env['use_lto']: env.Append(CCFLAGS=['-flto']) - env.Append(LINKFLAGS=['-flto']) + if not env['use_llvm'] and env.GetOption("num_jobs") > 1: + env.Append(LINKFLAGS=['-flto=' + str(env.GetOption("num_jobs"))]) + else: + env.Append(LINKFLAGS=['-flto']) if not env['use_llvm']: env['RANLIB'] = 'gcc-ranlib' env['AR'] = 'gcc-ar' |