-
Notifications
You must be signed in to change notification settings - Fork 31
Add JDK installation support (move from android-platform-support) #270
Copy link
Copy link
Closed
Labels
Description
Summary
Add JDK installation support to Xamarin.Android.Tools.AndroidSdk so that consumers (MAUI DevTools CLI, IDE extensions, build tasks) can auto-install missing JDKs instead of just reporting errors.
Background
The android-platform-support (internal) repository already has a working JavaDependencyInstaller implementation that:
- Discovers available JDK versions from the Xamarin Android Manifest Feed
- Downloads Microsoft OpenJDK archives (per-platform/architecture)
- Verifies downloads via SHA-1 checksums from the manifest
- Extracts and validates the JDK installation
This capability should be moved to the public Xamarin.Android.Tools.AndroidSdk package.
Proposed API Surface
JdkInstaller.DiscoverAsync()— find available JDK versions from the manifest feedJdkInstaller.InstallAsync(version, targetPath)— download, verify checksum, extract JDKJdkInstaller.IsValid(jdkPath)— validate an existing JDK installation
Manifest Feed
JDK archives are listed in the Xamarin Android Manifest Feed (https://aka.ms/AndroidManifestFeed/d{version}), which includes:
- Per-platform URLs (Windows, macOS, Linux)
- Per-architecture variants (x64, aarch64)
- SHA-1 checksums for download verification
Consumer
- MAUI DevTools CLI (
maui android install,maui android jdk install) — see MAUI DevTools Spec PR
Related
- MAUI DevTools spec §6.8: Shared Libraries & Code Reuse
Reactions are currently unavailable