From c6a981dceb4d43a24f7822dd350af2c88e06aabf Mon Sep 17 00:00:00 2001 From: jared Date: Wed, 8 Jul 2020 20:30:59 +0800 Subject: [PATCH] fix redifinition --- mkspecs/features/taoVersion.prf | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/mkspecs/features/taoVersion.prf b/mkspecs/features/taoVersion.prf index 771c8d6..02de757 100644 --- a/mkspecs/features/taoVersion.prf +++ b/mkspecs/features/taoVersion.prf @@ -27,15 +27,16 @@ build_pass { VER_PAT = $${PAT} VERSION = $${Ver} } - - DEFINES += TaoREVISION=$${REVISION} - DEFINES += TaoREVISIONSTR=\"\\\"$${REVISION}\\\"\" - DEFINES += TaoVer=\"\\\"$${Ver}\\\"\" - DEFINES += TaoMAJ=$${MAJ} - DEFINES += TaoMIN=$${MIN} - DEFINES += TaoPAT=$${PAT} - DEFINES += TaoDATETIME=\"\\\"$${_DATE_}\\\"\" - DEFINES += TaoCompilerVendor=\"\\\"$${QT_VERSION} $${QMAKE_PLATFORM} $${QMAKE_COMPILER} $${QMAKE_TARGET.arch}\\\"\" - message(DEFINES $$DEFINES) + !exists(TaoDefined) { + TaoDefined=1 + DEFINES += TaoREVISION=$${REVISION} + DEFINES += TaoREVISIONSTR=\"\\\"$${REVISION}\\\"\" + DEFINES += TaoVer=\"\\\"$${Ver}\\\"\" + DEFINES += TaoMAJ=$${MAJ} + DEFINES += TaoMIN=$${MIN} + DEFINES += TaoPAT=$${PAT} + DEFINES += TaoDATETIME=\"\\\"$${_DATE_}\\\"\" + DEFINES += TaoCompilerVendor=\"\\\"$${QT_VERSION} $${QMAKE_PLATFORM} $${QMAKE_COMPILER} $${QMAKE_TARGET.arch}\\\"\" + } } }