diff options
author | Thiago Macieira <thiago.macieira@intel.com> | 2014-06-26 14:56:06 -0700 |
---|---|---|
committer | hjk <hjk121@nokiamail.com> | 2014-07-23 11:12:02 +0200 |
commit | 1bd27f24fb7f7d82f4b67cffe43e0af644709106 (patch) | |
tree | 4f35d7ed8bb0a9e5f7a4381e0b09f69414d8f9d5 /mkspecs/win32-icc | |
parent | 849d1fece1da7136911464bc47439b4126145440 (diff) | |
download | qtbase-1bd27f24fb7f7d82f4b67cffe43e0af644709106.tar.gz |
Add link-time optimization support for Clang, GCC and ICC
GCC currently requires fat object files for static libraries, since the
linker would otherwise not load the .o file from the archive at all and
the linking would fail with a lot of undefined references. Clang on
Linux also needs this, but it has no equivalent flag, so enabling LTCG
for Clang on static libraries will result in linker error.
This commit does not add support for enabling it in configure. It can be
enabled on a per-project basis by doing CONFIG += ltcg or by passing
-config ltcg to qmake's command-line.
Change-Id: I52cf99f1ed9f1701e23a3b457ba3502fd28126ce
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Diffstat (limited to 'mkspecs/win32-icc')
-rw-r--r-- | mkspecs/win32-icc/qmake.conf | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/mkspecs/win32-icc/qmake.conf b/mkspecs/win32-icc/qmake.conf index a60d846e2f..d326cdeee3 100644 --- a/mkspecs/win32-icc/qmake.conf +++ b/mkspecs/win32-icc/qmake.conf @@ -23,6 +23,7 @@ QMAKE_CFLAGS_WARN_OFF = -W0 /Qwd673 QMAKE_CFLAGS_RELEASE = -O2 -MD QMAKE_CFLAGS_DEBUG = -Zi -MDd -Od QMAKE_CFLAGS_YACC = +QMAKE_CFLAGS_LTCG = -Qipo QMAKE_CFLAGS_SSE2 = -QxSSE2 QMAKE_CFLAGS_SSE3 = -QxSSE3 QMAKE_CFLAGS_SSSE3 = -QxSSSE3 @@ -45,6 +46,7 @@ QMAKE_CXXFLAGS_RTTI_OFF = QMAKE_CXXFLAGS_EXCEPTIONS_ON = -EHsc QMAKE_CXXFLAGS_EXCEPTIONS_OFF = QMAKE_CXXFLAGS_CXX11 = -Qstd=c++11 +QMAKE_CXXFLAGS_LTCG = $$QMAKE_CFLAGS_LTCG QMAKE_INCDIR = @@ -62,6 +64,7 @@ QMAKE_LFLAGS_DEBUG = /DEBUG QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:console QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:windows QMAKE_LFLAGS_DLL = /DLL +QMAKE_LFLAGS_LTCG = $$QMAKE_CFLAGS_LTCG QMAKE_EXTENSION_STATICLIB = lib QMAKE_LIBS = |