CMake: Fix glitch in module pri generation for Ninja Multi-Config

With Ninja Multi-Config, QMAKE_LIBS_FOO_DEBUG and QMAKE_LIBS_FOO_RELEASE
are generated, if their values differ. In that case we did not create an
empty QMAKE_LIBS_FOO assignment. That, however, is needed to make the
library 'foo' known to qmake_use.prf.

This amends bd98ba0d17.

Fixes: QTBUG-89387
Change-Id: I80e23746e6ba6ff7f5f4186116232395814cee15
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
This commit is contained in:
Joerg Bornemann 2020-12-15 22:30:36 +01:00
parent 41aff1cd93
commit e40b31fe68

View File

@ -65,6 +65,7 @@ foreach(lib ${known_libs})
qmake_list(value_debug ${value_debug})
string(APPEND content "QMAKE_LIBS_${lib} = ${value_debug}\n")
else()
string(APPEND content "QMAKE_LIBS_${lib} =\n")
if(value_debug)
qmake_list(value_debug ${value_debug})
string(APPEND content "QMAKE_LIBS_${lib}_DEBUG = ${value_debug}\n")