Android installation instructions in INSTALL docs
An award-winning drawing program for children of all ages
Brought to you by:
wkendrick
Add step-by-step instructions on how to build Tux Paint for Android to the INSTALL docs (source found in tuxpaint-docs
repository).
(@wkendrick is here to assist!)
Hi,
Basically is a matter of run
gradle build
in the Tuxpaint-Android git clone.
One will need a recent enough version of gradle, and SDK / NDK tools Google
Also, to compile the latest Tux Paint, one has to sync SF git with github, I use the attached script that backups the app/src/main/jni/tuxpaint directory in the Tuxpaint-Android github repo and makes a build of SF's Tux Paint to generate transslations and other stuff that is not autogenerated in the Android builds then copies the tuxpaint SF to the place.
For it to run you need the tuxpaint and Tuxpaint-Android sources one next to other, and the script in the directory containing both.
You also need to fill the app/src/main/assets directory
cd app/src/main/jni/tuxpaint && ./mkzip_assets.sh
Currently, Gradle build generates some variants: Playstore, debug Playstore, offPlaystore and debugoffPlastore. You must sign the non-debug ones to be able to install them.
PlayStore ones are intended to be uploaded to Google Play, but I don't know the process.
offPlayStore is the flavor that we distribute in SF and that is used in F-droid.
To trigger a build from F-droid, it suffices to tag a commit and push it to github, it doesn't warrant that the build will succeed though, so I usually run a local F-droid server to test the build and eventually adapt the F-droid's build receipt before pushing the tag to github.
The builds I distribute are all made with that local F-droid server, it has the advantage of packing the sources and logs, sign the apk, and more important to me, it uses the same tools F-droid will use to build Tux Paint so I can see possible problems beforehand.
The original instructions by JianWei Zhang with some additions
https://github.com/tux4kids/Tuxpaint-Android/blob/master/README.md
The receipt used for f-droid builds is in the metadata dir of
https://gitlab.com/fdroid/fdroiddata
The f-droid server code is at
https://gitlab.com/fdroid/fdroidserver
To generate the server you will need a Gb free on disk and run the makebuildserver tool they provide, then, from the root of fdroiddata, run ../fdroidserver/fdroid buil --server org.tuxpaint:9288
You will need to add the following to the metadata/org.tuxpaint.yml file to compile the current Tux Paint
versionCode: 9288
commit: b578ba42
subdir: app
sudo:
gradle:
prebuild:
scandelete:
ndk: r19c
AutoUpdateMode: Version %v
UpdateCheckMode: Tags
CurrentVersion: 0.9.29-RC2
CurrentVersionCode: 9288
Hope this helps, let me know if you have doubts
I've added an Android section to INSTALL. @perepujal can you check it for accuracy, please? (Plaintext English snapshot can be seen in Git here: https://sourceforge.net/p/tuxpaint/tuxpaint/ci/master/tree/docs/en/INSTALL.txt (Currently starting around line 800) Thanks!
Lines 838 to 840;
"offPlaystore" is the
flavor that we distribute as APK files on the Tux Paint website and
SourceForge file hosting, and send to the F-Droid app. repository.)
Capitalization, should be offPlayStore, this also appears somewere else.
We don't send APK files to F-Droid, their server checks if there are changes in the Github repo and autogenerate a new receipt for each new TAG they find, then try to build it.
Other than that, all looks fine :)
Pere
Thanks! Adjusted it. Closing ticket. We can always iterate more later, if needed.