macOS: add version to info.plist

This commit is contained in:
selsta 2020-02-13 03:19:18 +01:00
parent eb7fae92ef
commit 478fddaf57
No known key found for this signature in database
GPG key ID: 2EA0A99A8B07AE5E
2 changed files with 10 additions and 0 deletions

View file

@ -518,6 +518,7 @@ DISTFILES += \
VERSION = $$cat('version.js', lines)
VERSION = $$find(VERSION, 'GUI_VERSION')
VERSION_LONG = $$replace(VERSION, '.*\"v(.*)\"', '\1')
VERSION = $$replace(VERSION, '.*(\d+\.\d+\.\d+\.\d+).*', '\1')
# windows application icon
@ -525,4 +526,7 @@ RC_ICONS = images/appicon.ico
# mac Info.plist & application icon
QMAKE_INFO_PLIST = $$PWD/share/Info.plist
macx {
QMAKE_POST_LINK += sed -i "''" -e "s/@VERSION@/$$VERSION/g" -e "s/@VERSION_LONG@/$$VERSION_LONG/g" "$$sprintf("%1/%2/%3.app", $$OUT_PWD, $$DESTDIR, $$TARGET)/Contents/Info.plist";
}
ICON = $$PWD/images/appicon.icns

View file

@ -26,6 +26,12 @@
<key>CFBundleIdentifier</key>
<string>org.monero-project.monero-wallet-gui</string>
<key>CFBundleVersion</key>
<string>@VERSION_LONG@</string>
<key>CFBundleShortVersionString</key>
<string>@VERSION@</string>
<key>NSSupportsAutomaticGraphicsSwitching</key>
<true/>