Commit 1dfad46f authored by Don Gagne's avatar Don Gagne

Correct version info for all OSX/iOS builds

parent 942d404a
...@@ -9,9 +9,9 @@ ...@@ -9,9 +9,9 @@
<key>CFBundlePackageType</key> <key>CFBundlePackageType</key>
<string>APPL</string> <string>APPL</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>227</string> <string>###</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>2.0.0</string> <string>#.#.#</string>
<key>CFBundleSignature</key> <key>CFBundleSignature</key>
<string>????</string> <string>????</string>
<key>CFBundleExecutable</key> <key>CFBundleExecutable</key>
......
...@@ -88,16 +88,24 @@ MobileBuild { ...@@ -88,16 +88,24 @@ MobileBuild {
# set the QGC version from git # set the QGC version from git
exists ($$PWD/.git) { exists ($$PWD/.git) {
GIT_DESCRIBE = $$system(git --git-dir $$PWD/.git --work-tree $$PWD describe --always --tags) GIT_DESCRIBE = $$system(git --git-dir $$PWD/.git --work-tree $$PWD describe --always --tags)
GIT_HASH = $$system(git rev-parse HEAD) GIT_HASH = $$system(git rev-parse HEAD)
VERSION = $$replace(GIT_DESCRIBE, "v", "") VERSION = $$replace(GIT_DESCRIBE, "v", "")
VERSION = $$replace(VERSION, "-", ".") VERSION = $$replace(VERSION, "-", ".")
VERSION = $$section(VERSION, ".", 0, 3) VERSION = $$section(VERSION, ".", 0, 3)
message(QGroundControl version $${GIT_DESCRIBE} hash $${GIT_HASH}) MacBuild {
MAC_VERSION = $$section(VERSION, ".", 0, 2)
MAC_BUILD = $$section(VERSION, ".", 3, 3)
message(QGroundControl version $${MAC_VERSION} build $${MAC_BUILD} describe $${GIT_DESCRIBE} hash $${GIT_HASH})
} else {
message(QGroundControl version $${VERSION} describe $${GIT_DESCRIBE} hash $${GIT_HASH})
}
} else { } else {
GIT_DESCRIBE = None GIT_DESCRIBE = None
GIT_HASH = None GIT_HASH = None
VERSION = 0.0.0 # Marker to indicate out-of-tree build VERSION = 0.0.0 # Marker to indicate out-of-tree build
MAC_VERSION = 0.0.0
MAC_BUILD = 0
} }
DEFINES += GIT_TAG=\"\\\"$$GIT_DESCRIBE\\\"\" DEFINES += GIT_TAG=\"\\\"$$GIT_DESCRIBE\\\"\"
......
...@@ -50,6 +50,12 @@ WindowsBuild { ...@@ -50,6 +50,12 @@ WindowsBuild {
# Perform platform specific setup # Perform platform specific setup
# #
iOSBuild | MacBuild {
# Update version info in bundle
QMAKE_POST_LINK += && /usr/libexec/PlistBuddy -c \"Set :CFBundleShortVersionString $${MAC_VERSION}\" $$DESTDIR/$${TARGET}.app/Contents/Info.plist
QMAKE_POST_LINK += && /usr/libexec/PlistBuddy -c \"Set :CFBundleVersion $${MAC_BUILD}\" $$DESTDIR/$${TARGET}.app/Contents/Info.plist
}
MacBuild { MacBuild {
# Copy non-standard frameworks into app package # Copy non-standard frameworks into app package
QMAKE_POST_LINK += && rsync -a --delete $$BASEDIR/libs/lib/Frameworks $$DESTDIR/$${TARGET}.app/Contents/ QMAKE_POST_LINK += && rsync -a --delete $$BASEDIR/libs/lib/Frameworks $$DESTDIR/$${TARGET}.app/Contents/
......
...@@ -17,11 +17,11 @@ ...@@ -17,11 +17,11 @@
<key>CFBundlePackageType</key> <key>CFBundlePackageType</key>
<string>APPL</string> <string>APPL</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>1.0</string> <string>#.#.#</string>
<key>CFBundleSignature</key> <key>CFBundleSignature</key>
<string>????</string> <string>????</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>1.0</string> <string>###</string>
<key>LSRequiresIPhoneOS</key> <key>LSRequiresIPhoneOS</key>
<true/> <true/>
<key>NOTE</key> <key>NOTE</key>
......
...@@ -17,11 +17,11 @@ ...@@ -17,11 +17,11 @@
<key>CFBundlePackageType</key> <key>CFBundlePackageType</key>
<string>APPL</string> <string>APPL</string>
<key>CFBundleShortVersionString</key> <key>CFBundleShortVersionString</key>
<string>1.0</string> <string>#.#.#</string>
<key>CFBundleSignature</key> <key>CFBundleSignature</key>
<string>????</string> <string>????</string>
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>1.0</string> <string>###</string>
<key>LSRequiresIPhoneOS</key> <key>LSRequiresIPhoneOS</key>
<true/> <true/>
<key>NOTE</key> <key>NOTE</key>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment