-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support building and running on Android (#36)
* Include vendored source code for `openssl` and `sqlite` so that they can be built from source for the Android target. * Add `login.toml`: a temp hack to specify your username and password on platforms where command-line arguments aren't supported, such as Android and other mobie platforms. * This file should not be committed to version control with a valid username and password; hence why it's in .gitignore. * Switch to `log!()` and `error!()` macros instead of `println!()` and `eprintln!()`, which work on Android. * Export environment variables that the `cc` crate relies on to build and link Android-specific native target libraries, which currently include openssl and sqlite. * These variables only affect builds for Android targets. * We have modified the upstream `cargo-makepad` to automatically export those environment variables for Android builds, which frees the app developer (us) from the burden of having to do so. * We have also modified the upstream `cargo-makepad` to support installing the full Android NDK at the canonical path. * See <makepad/makepad#388> *Add instructions for building and running Robrix on Android.
- Loading branch information
1 parent
76099cc
commit 1c3e2bf
Showing
12 changed files
with
225 additions
and
98 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,3 +2,6 @@ | |
.vscode | ||
|
||
.DS_Store | ||
|
||
## Temp hack to support login on mobile platforms. | ||
login.toml |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
username = " " | ||
password = " " | ||
|
||
### Please fill in your username and password above. | ||
### | ||
### Robrix does not yet have a login splash screen. | ||
### Thus, on desktop platforms, we allow the user to | ||
### pass in a username and password as command line arguments. | ||
### | ||
### However, on mobile platforms, there is no way to reliably | ||
### pass in command line arguments. | ||
### Instead, we enable the mobile apps to read them from a copy | ||
### of this file that is included in the app package files. | ||
### | ||
### Only the two username and password fields are supported. | ||
### | ||
### Note that for obvious reasons you should not commit this file | ||
### or upload it to a public repo with your actual username and password in it. | ||
### Thus, we have added it to the .gitignore file. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.