mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-22 00:06:12 -05:00
Disable Qt deprecation warnings on Qt 6 builds
These are too noisy, as we get thousands of warnigs due to QVariant::Type usage in headers which we need for Qt 5 build compatibility
This commit is contained in:
parent
1dfb788c17
commit
8bf470baa0
@ -824,10 +824,14 @@ if(MSVC)
|
||||
add_definitions(-DNOMINMAX)
|
||||
endif()
|
||||
|
||||
# Prevent build when Qt api deprecated before this Qt version is used:
|
||||
add_definitions(-DQT_DEPRECATED_WARNINGS)
|
||||
# Unfortunately Qwt uses deprecated QString::null in headers, preventing this being raised above 5.8
|
||||
add_definitions(-DQT_DISABLE_DEPRECATED_BEFORE=0x050800)
|
||||
if(BUILD_WITH_QT6)
|
||||
# Qt deprecated warnings are too noisy for now -- we have a LOT of QVariant::Type usage
|
||||
# in order to maintain Qt5 compatibility
|
||||
add_definitions(-DQT_NO_DEPRECATED_WARNINGS)
|
||||
else()
|
||||
# Unfortunately Qwt uses deprecated QString::null in headers, preventing this being raised above 5.8
|
||||
add_definitions(-DQT_DISABLE_DEPRECATED_BEFORE=0x050800)
|
||||
endif()
|
||||
|
||||
# For fast string concatenation
|
||||
add_definitions(-DQT_USE_QSTRINGBUILDER)
|
||||
|
Loading…
x
Reference in New Issue
Block a user