Skip to content
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

[doc]update android doc with gradle/jdk version #37368

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 20 additions & 15 deletions docs/platforms/android/android_building.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,17 @@ There are following Apps on Android

<hr>

- [Building Android](#building-android)
- [Source files](#source-files)
- [Requirements for building](#requirements-for-building)
- [Linux](#linux)
- [MacOS](#macos)
- [ABIs and TARGET_CPU](#abis-and-target_cpu)
- [Gradle & JDK Version](#gradle--jdk-version)
- [Preparing for build](#preparing-for-build)
- [Building Android CHIPTool from scripts](#building-android-chiptool-from-scripts)
- [Building Android CHIPTool from Android Studio](#building-android-chiptool-from-android-studio)
- [Building Android CHIPTest from scripts](#building-android-chiptest-from-scripts)
- [Building Android](#building-android)
- [Source files](#source-files)
- [Requirements for building](#requirements-for-building)
- [Linux](#linux)
- [MacOS](#macos)
- [ABIs and TARGET\_CPU](#abis-and-target_cpu)
- [Gradle \& JDK Version](#gradle--jdk-version)
- [Preparing for build](#preparing-for-build)
- [Building Android CHIPTool from scripts](#building-android-chiptool-from-scripts)
- [Building Android CHIPTool from Android Studio](#building-android-chiptool-from-android-studio)
- [Building Android CHIPTest from scripts](#building-android-chiptest-from-scripts)

<hr>

Expand Down Expand Up @@ -97,11 +97,10 @@ architecture:

### Gradle & JDK Version

We are using Gradle 7.1.1 for all android project which does not support Java 17
(https://docs.gradle.org/current/userguide/compatibility.html) while the default
JDK version on MacOS for Apple Silicon is 'openjdk 17.0.1' or above.
All Android projects utilize Gradle version 7.3.3 and JDK version 17.0.

Using JDK bundled with Android Studio will help with that.
For developers using Android Studio in MAC os, the JAVA_HOME environment variable should be
configured as follows:

Android Studio Dolphin and below:

Expand All @@ -115,6 +114,12 @@ Android Studio Electric Eel 2022.1.1 and above:
export JAVA_HOME=/Applications/Android\ Studio.app/Contents/jbr/Contents/Home/
```

For developer using openjdk-17-jdk in Linux, the JAVA_HOME environment variable should be
configured as follows:
```shell
export JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64
```

<hr>

<a name="preparing"></a>
Expand Down
Loading