Browse Source

Update Kivy build instructions

My PRs have been merged!
3.1
Johann Bauer 7 years ago
parent
commit
7ab9fa5be4
  1. 23
      gui/kivy/Readme.md

23
gui/kivy/Readme.md

@ -5,9 +5,8 @@ The Kivy GUI is used with Electrum on Android devices. To generate an APK file,
## 1. Install python-for-android (p4a) ## 1. Install python-for-android (p4a)
p4a is used to package Electrum, Python, SDL and a bootstrap Java app into an APK file. p4a is used to package Electrum, Python, SDL and a bootstrap Java app into an APK file.
We patched p4a to add some functionality we need for Electrum. Until those changes are We patched p4a to add some functionality we need for Electrum. Until those changes are
merged into p4a, you need to merge them locally (into the stable branch): merged into p4a, you need to merge them locally (into the master branch):
1. [kivy/python-for-android#1213](https://github.com/kivy/python-for-android/pull/1213)
2. [kivy/python-for-android#1217](https://github.com/kivy/python-for-android/pull/1217) 2. [kivy/python-for-android#1217](https://github.com/kivy/python-for-android/pull/1217)
Something like this should work: Something like this should work:
@ -17,31 +16,18 @@ cd /opt
git clone https://github.com/kivy/python-for-android git clone https://github.com/kivy/python-for-android
cd python-for-android cd python-for-android
git remote add agilewalker https://github.com/agilewalker/python-for-android git remote add agilewalker https://github.com/agilewalker/python-for-android
git remote add bauerj https://github.com/bauerj/python-for-android git checkout a036f4442b6a23
git checkout stable
git fetch agilewalker git fetch agilewalker
git merge agilewalker/master git merge agilewalker/master
git fetch bauerj
git merge bauerj/add-activity
``` ```
## 2. Install buildozer ## 2. Install buildozer
Buildozer is a frontend to p4a. Of course it needs to be patched too: Buildozer is a frontend to p4a. Luckily we don't need to patch it:
1. [kivy/buildozer#612](https://github.com/kivy/python-for-android/pull/1213)
```sh ```sh
cd /opt cd /opt
git clone https://github.com/kivy/buildozer git clone https://github.com/kivy/buildozer
cd buildozer cd buildozer
git remote add bauerj https://github.com/bauerj/buildozer
git fetch bauerj
git merge bauerj/add-activity
```
You also want to install it:
```sh
sudo python3 setup.py install sudo python3 setup.py install
``` ```
@ -73,8 +59,7 @@ Run `contrib/make_apk`.
Update your Android build tools to version 27 like described above. Update your Android build tools to version 27 like described above.
## Why do I get errors like `(use -source 7 or higher to enable multi-catch statement)` while compiling? ## Why do I get errors like `(use -source 7 or higher to enable multi-catch statement)` while compiling?
Use the `stable` branch of python-for-android. Make sure that your p4a installation includes commit a3cc78a6d1a107cd3b6bd28db8b80f89e3ecddd2.
[This commit](https://github.com/kivy/python-for-android/commit/3534a761b17040755accf941f898cc66b905e8db) in master is the culprit.
## I changed something but I don't see any differences on the phone. What did I do wrong? ## I changed something but I don't see any differences on the phone. What did I do wrong?
You probably need to clear the cache: `rm -rf .buildozer/android/platform/build/{build,dists}` You probably need to clear the cache: `rm -rf .buildozer/android/platform/build/{build,dists}`

Loading…
Cancel
Save