Fix build on Windows.

--HG--
branch : develop
This commit is contained in:
Roman Telezhynskyi 2019-11-29 21:16:37 +02:00
parent 3c69b425ec
commit 80418045b0

View File

@ -100,9 +100,26 @@ CONFIG(release, debug|release){
} else { } else {
!macx:!*msvc*{ !macx:!*msvc*{
noDebugSymbols{ # For enable run qmake with CONFIG+=noDebugSymbols noDebugSymbols{ # For enable run qmake with CONFIG+=noDebugSymbols
# Strip after you link all libaries. win32:!*msvc*{
# Strip debug symbols.
QMAKE_POST_LINK += objcopy --strip-debug bin/${TARGET}
}
unix:!macx{
# Strip debug symbols.
QMAKE_POST_LINK += objcopy --strip-debug ${TARGET} QMAKE_POST_LINK += objcopy --strip-debug ${TARGET}
}
} else { } else {
win32:!*msvc*{
# Strip debug symbols.
QMAKE_POST_LINK += objcopy --only-keep-debug bin/${TARGET} bin/${TARGET}.dbg &&
QMAKE_POST_LINK += objcopy --strip-debug bin/${TARGET} &&
QMAKE_POST_LINK += objcopy --add-gnu-debuglink="bin/${TARGET}.dbg" bin/${TARGET}
QMAKE_DISTCLEAN += bin/${TARGET}.dbg
}
unix:!macx{
# Strip debug symbols. # Strip debug symbols.
QMAKE_POST_LINK += objcopy --only-keep-debug ${TARGET} ${TARGET}.dbg && QMAKE_POST_LINK += objcopy --only-keep-debug ${TARGET} ${TARGET}.dbg &&
QMAKE_POST_LINK += objcopy --strip-debug ${TARGET} && QMAKE_POST_LINK += objcopy --strip-debug ${TARGET} &&
@ -113,3 +130,4 @@ CONFIG(release, debug|release){
} }
} }
} }
}