mirror of
https://github.com/servo/servo.git
synced 2025-07-25 16:20:36 +01:00
Update README for Android
https://github.com/servo/servo/pull/21094 automates some things.
This commit is contained in:
parent
ce430566cd
commit
f0275d184b
1 changed files with 8 additions and 16 deletions
24
README.md
24
README.md
|
@ -183,8 +183,8 @@ list of installed components. It is not on by default. Visual Studio 2017 MUST i
|
||||||
|
|
||||||
#### Cross-compilation for Android
|
#### Cross-compilation for Android
|
||||||
|
|
||||||
Pre-installed Android tools are needed. See wiki for
|
Run `./mach bootstrap-android` to get Android-specific tools. See wiki for
|
||||||
[details](https://github.com/servo/servo/wiki/Building-for-Android)
|
[details](https://github.com/servo/servo/wiki/Building-for-Android).
|
||||||
|
|
||||||
## The Rust compiler
|
## The Rust compiler
|
||||||
|
|
||||||
|
@ -240,26 +240,18 @@ though of course it doesn’t produce a binary you can run.
|
||||||
|
|
||||||
### Building for Android target
|
### Building for Android target
|
||||||
|
|
||||||
|
For ARM (`armv7-linux-androideabi`, most phones):
|
||||||
|
|
||||||
``` sh
|
``` sh
|
||||||
git clone https://github.com/servo/servo
|
|
||||||
cd servo
|
|
||||||
|
|
||||||
export ANDROID_SDK="/path/to/sdk"
|
|
||||||
export ANDROID_NDK="/path/to/ndk"
|
|
||||||
export ANDROID_TOOLCHAIN="/path/to/toolchain"
|
|
||||||
export PATH="$PATH:/path/to/toolchain/bin"
|
|
||||||
|
|
||||||
./mach build --release --android
|
./mach build --release --android
|
||||||
./mach package --release --android
|
./mach package --release --android
|
||||||
```
|
```
|
||||||
|
|
||||||
Rather than setting the `ANDROID_*` environment variables every time, you can
|
For x86 (typically for the emulator):
|
||||||
also create a `.servobuild` file and then edit it to contain the correct paths
|
|
||||||
to the Android SDK/NDK tools:
|
|
||||||
|
|
||||||
```
|
```sh
|
||||||
cp servobuild.example .servobuild
|
./mach build --release --target i686-linux-android
|
||||||
# edit .servobuild
|
./mach package --release --target i686-linux-android
|
||||||
```
|
```
|
||||||
|
|
||||||
## Running
|
## Running
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue