Skip to content

Commit 9d23de4

Browse files
[Xamarin.Android.Build.Tasks] allow JDK 17 usage (#8313)
Context: #8309 Context: https://learn.microsoft.com/java/openjdk/download#openjdk-17 Classic Xamarin.Android apps appear to work with JDK-17, just by doing: msbuild -r -bl -t:SignAndroidPackage ^ -p:JavaSdkDirectory="C:\Program Files\Microsoft\jdk-17.0.8.101-hotspot" ^ -p:LatestSupportedJavaVersion=17.99 I see log messages calling a JDK 17 `javac` like: _CompileJava: C:\Program Files\Microsoft\jdk-17.0.8.101-hotspot\bin\javac.exe -J-Dfile.encoding=UTF8 "@C:\Users\jopepper\AppData\Local\Temp\tmp119C.tmp" -target 1.8 -source 1.8 Update `$(LatestSupportedJavaVersion)` to allow usage of JDK 17.
1 parent 05bc105 commit 9d23de4

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/Xamarin.Android.Build.Tasks/Xamarin.Android.Common.props.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
<ImplicitlyExpandNETStandardFacades>false</ImplicitlyExpandNETStandardFacades>
1010
<CopyNuGetImplementations Condition=" '$(CopyNuGetImplementations)' == ''">true</CopyNuGetImplementations>
1111
<YieldDuringToolExecution Condition="'$(YieldDuringToolExecution)' == ''">true</YieldDuringToolExecution>
12-
<LatestSupportedJavaVersion Condition="'$(LatestSupportedJavaVersion)' == ''">11.0.99</LatestSupportedJavaVersion>
12+
<LatestSupportedJavaVersion Condition="'$(LatestSupportedJavaVersion)' == ''">17.0.99</LatestSupportedJavaVersion>
1313
<MinimumSupportedJavaVersion Condition="'$(MinimumSupportedJavaVersion)' == ''">1.6.0</MinimumSupportedJavaVersion>
1414
<AndroidVersionCodePattern Condition=" '$(AndroidUseLegacyVersionCode)' != 'True' And '$(AndroidVersionCodePattern)' == '' ">{abi}{versionCode:D5}</AndroidVersionCodePattern>
1515
<AndroidResourceGeneratorTargetName>UpdateGeneratedFiles</AndroidResourceGeneratorTargetName>

0 commit comments

Comments
 (0)