-
Notifications
You must be signed in to change notification settings - Fork 245
Draft: Android CI production build and Play Store auto-submission #2909
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 4 commits
90e3b78
d7fb81a
5418d13
4601afc
1ff0b26
689fe42
637ef50
eda0344
153bc77
dd6c0d6
36f6023
e051ec9
8daa639
8e4bd0a
33d5f69
8f974e8
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -229,18 +229,42 @@ win32 { | |
| LIBS += -framework AVFoundation \ | ||
| -framework AudioToolbox | ||
| } else:android { | ||
| ANDROID_ABIS = armeabi-v7a arm64-v8a x86 x86_64 | ||
| # ANDROID_ABIS = armeabi-v7a arm64-v8a x86 x86_64 | ||
| # note: only armeabi-v7a arm64-v8a are targeted, others are dead/deprecated | ||
|
ann0see marked this conversation as resolved.
Outdated
|
||
|
|
||
| # get ANDROID_ABIS from environment - passed directly to qmake | ||
| ANDROID_ABIS = $$getenv(ANDROID_ABIS) | ||
|
|
||
| # if ANDROID_ABIS is passed as env var to qmake, will override this | ||
| # !defined(ANDROID_ABIS, var):ANDROID_ABIS = arm64-v8a | ||
|
|
||
| # Experiments show likely better results with Android 10+ devices | ||
| ANDROID_MIN_SDK_VERSION = 29 | ||
| ANDROID_TARGET_SDK_VERSION = 32 | ||
| ANDROID_VERSION_NAME = $$VERSION | ||
| ANDROID_VERSION_CODE = $$system(git log --oneline | wc -l) | ||
|
|
||
| # date-based unique value - prevent clashes in Play Store build numbering | ||
| !defined(ANDROID_VERSION_CODE, var):ANDROID_VERSION_CODE = $$system(date +%s | cut -c 2-) | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This will not work on windows I suppose? Wouldn't the git commit hash or something else be better?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The CI is obviously targeted purely for Linux. Android Version Code requires an integer <=2100000000. I don't like relying on git log because you need a separate version code for armeabi7 and armv8 builds.
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
But as it's in Jamulus.pro we should ensure cross compatibility. Even if it's a noop. |
||
|
|
||
| # make separate version codes for each abi build otherwise Play Store rejects | ||
| contains (ANDROID_ABIS, armeabi-v7a) { | ||
| ANDROID_VERSION_CODE = $$num_add($$ANDROID_VERSION_CODE, 1) | ||
| message("Setting for armeabi-v7a: ANDROID_VERSION_CODE=$${ANDROID_VERSION_CODE}") | ||
| } else { | ||
| message("Setting for armv8a: ANDROID_VERSION_CODE=$${ANDROID_VERSION_CODE}") | ||
| } | ||
|
|
||
| message("Setting ANDROID_VERSION_NAME=$${ANDROID_VERSION_NAME} ANDROID_VERSION_CODE=$${ANDROID_VERSION_CODE}") | ||
|
|
||
| # liboboe requires C++17 for std::timed_mutex | ||
| CONFIG += c++17 | ||
|
|
||
| QT += androidextras | ||
| # For device recording permissions | ||
| # Qt6: | ||
| QT += core-private | ||
|
|
||
| # enabled only for debugging on android devices | ||
| DEFINES += ANDROIDDEBUG | ||
| #DEFINES += ANDROIDDEBUG | ||
|
|
||
| target.path = /tmp/your_executable # path on device | ||
| INSTALLS += target | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.