From c77b165cf027791213ac2b8e6955b5053d288408 Mon Sep 17 00:00:00 2001 From: Roman Telezhynskyi Date: Mon, 16 Mar 2015 18:31:27 +0200 Subject: [PATCH] Can't defeat PATH variable on Mac OS. --HG-- branch : release --- src/app/app.pro | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/app/app.pro b/src/app/app.pro index 98ad636e1..27e5d2313 100644 --- a/src/app/app.pro +++ b/src/app/app.pro @@ -131,8 +131,13 @@ CONFIG(debug, debug|release){ QMAKE_LFLAGS_RELEASE = } + macx{ + HG = /usr/local/bin/hg # Can't defeat PATH variable on Mac OS. + }else { + HG = hg # All other platforms all OK. + } #latest tag distance number for using in version - HG_DISTANCE=$$system(hg log -r. --template '{latesttagdistance}') + HG_DISTANCE=$$system($${HG} log -r. --template '{latesttagdistance}') isEmpty(HG_DISTANCE){ HG_DISTANCE = 0 # if we can't find local revision left 0. } @@ -141,10 +146,10 @@ CONFIG(debug, debug|release){ #build revision number for using in version unix { - HG_HESH=$$system("hg log -r. --template '{node|short}'") + HG_HESH=$$system("$${HG} log -r. --template '{node|short}'") } else { # Use escape character before "|" on Windows - HG_HESH=$$system(hg log -r. --template "{node^|short}") + HG_HESH=$$system($${HG} log -r. --template "{node^|short}") } isEmpty(HG_HESH){ HG_HESH = "unknown" # if we can't find build revision left unknown.