summaryrefslogtreecommitdiff
path: root/Tools/qmake
diff options
context:
space:
mode:
authorKai Koehne <kai.koehne@theqtcompany.com>2015-11-16 14:27:39 +0100
committerKai Koehne <kai.koehne@theqtcompany.com>2015-11-16 14:46:40 +0000
commitccff714c4a863ec4285f9a2ab5e881ba4f8ed42f (patch)
tree7fc32bfe211198ac8ac224ffd775ef74e2900f93 /Tools/qmake
parent93cc8d306f8033551fb60e2e1f8f480330778a21 (diff)
downloadqtwebkit-ccff714c4a863ec4285f9a2ab5e881ba4f8ed42f.tar.gz
Fix link error in MSVC
Since qtbase/e88334e0 we must not put MSVC linker flags into LIBS or LIBS_PRIVATE. QMAKE_LFLAGS is the right place. This fixes a build error with MSVC: LINK : fatal error LNK1181: cannot open input file '\OPT:REF.obj' A similar fix was already applied to qtwebengine (295a915b5ae66). Change-Id: I7972651cd6e61ef3ecd413be290e49baec29a770 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Diffstat (limited to 'Tools/qmake')
-rw-r--r--Tools/qmake/mkspecs/features/functions.prf3
1 files changed, 2 insertions, 1 deletions
diff --git a/Tools/qmake/mkspecs/features/functions.prf b/Tools/qmake/mkspecs/features/functions.prf
index 9602c2051..dc0c78f97 100644
--- a/Tools/qmake/mkspecs/features/functions.prf
+++ b/Tools/qmake/mkspecs/features/functions.prf
@@ -269,7 +269,8 @@ defineTest(linkAgainstLibrary) {
mac {
LIBS += -Wl,-force_load,$${path}$${QMAKE_DIR_SEP}lib$${target}.a
} else:win32-msvc*|wince*|win32-icc {
- LIBS += /OPT:REF -l$$target
+ LIBS += -l$$target
+ QMAKE_LFLAGS += /OPT:REF
} else {
CONFIG *= no_smart_library_merge
LIBS += -Wl,-whole-archive -l$$target -Wl,-no-whole-archive