From 265b1369a397efd47fc13dbcb76a3439cccfe207 Mon Sep 17 00:00:00 2001 From: Niclas Rosenvik Date: Tue, 1 Nov 2022 22:31:27 +0100 Subject: [PATCH] Fix redefine of QT_NO_VERSION_TAGGING warnings If a user requests no version tagging by defining QT_NO_VERSION_TAGGING a lot of redefine warnings will be output from the compiler when building corelib. So only define QT_NO_VERSION_TAGGING if it is not already defined. Pick-to: 6.4 Change-Id: I56609b3589184bda7bec52d168d9fd11e2f14a2c Reviewed-by: Thiago Macieira --- src/corelib/global/qversiontagging.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/corelib/global/qversiontagging.h b/src/corelib/global/qversiontagging.h index 4e0eb68bbd..e64cae1d87 100644 --- a/src/corelib/global/qversiontagging.h +++ b/src/corelib/global/qversiontagging.h @@ -73,7 +73,7 @@ struct QVersionTag }; } -#if defined(QT_BUILD_CORE_LIB) || defined(QT_BOOTSTRAPPED) || defined(QT_STATIC) +#if !defined(QT_NO_VERSION_TAGGING) && (defined(QT_BUILD_CORE_LIB) || defined(QT_BOOTSTRAPPED) || defined(QT_STATIC)) // don't make tags in QtCore, bootstrapped systems or if the user asked not to # define QT_NO_VERSION_TAGGING #endif