bazelbuild / bazelbuild/rules_android

How to `mobile-install` a desugared app that has JDK 21 dependencies?

Open
#510 2 comments 1 reaction 0 assignees View on GitHub
Dominant language
Java
Stars
203
Forks
95
PR merge metrics
No merged PRs in 30d

Description

I'm building an app that depends on a library specifically built for JVM 21. As the java tools use JDK 17, there's an error from `DesugarDexSharding`:

```
Error: java.lang.IllegalArgumentException: Unsupported class file major version 65
```

What's the recommended way to deal with this, and what will be the eventual fix?

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the failure through mobile-install with a dependency built for JVM 21, then trace how the Java tools invoke DesugarDexSharding under JDK 17. Determine the supported way to handle class file major version 65 and document what eventual fix is required.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, java
Domain
build-system, mobile
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.