Remove Java.Base#1453
Draft
simonrozsival wants to merge 1 commit into
Draft
Conversation
Remove the standalone java.base binding assembly and its reference assembly output now that the Java.Runtime.Environment-based desktop Java path is being removed. Also remove Java.Interop.Sdk special handling for Java.Base references and stale docs/comments. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
This PR removes the in-repo Java.Base binding assembly (and its associated generated/transform inputs) now that the standalone desktop/JRE binding path has been retired, and cleans up remaining solution/tooling/docs references to it.
Changes:
- Remove the
src/Java.Baseproject (csproj/targets) and Java.Base-specific transform inputs/files. - Remove
Java.Basefrom the solution and SDK/tooling integration points. - Clean up stale Java.Base-specific comments in generator/runtime and repo documentation.
Show a summary per file
| File | Description |
|---|---|
| tools/generator/SourceWriters/GenericExplicitInterfaceImplementationProperty.cs | Updates a comment to remove Java.Base mention while preserving existing JavaInterop1 workaround explanation. |
| src/Java.Interop/Java.Interop/JniPeerMembers.JniInstanceMethods.cs | Removes stacktrace comment lines that referenced deleted Java.Base test/project paths. |
| src/Java.Base/Transforms/methodmap.csv | Deleted as part of removing Java.Base binding transforms. |
| src/Java.Base/Transforms/Metadata.xml | Deleted as part of removing Java.Base binding transforms. |
| src/Java.Base/Transforms/map.csv | Deleted as part of removing Java.Base binding transforms. |
| src/Java.Base/Transforms/enumflags | Deleted as part of removing Java.Base binding transforms. |
| src/Java.Base/Java.Lang/Throwable.cs | Deleted Java.Base-specific partial binding code. |
| src/Java.Base/Java.Lang/Thread.cs | Deleted Java.Base-specific partial binding code. |
| src/Java.Base/Java.Lang/StringBuilder.cs | Deleted Java.Base-specific partial binding code. |
| src/Java.Base/Java.Lang/StringBuffer.cs | Deleted Java.Base-specific partial binding code. |
| src/Java.Base/Java.Lang/String.cs | Deleted Java.Base-specific partial binding code. |
| src/Java.Base/Java.Lang/Object.cs | Deleted Java.Base-specific partial binding code. |
| src/Java.Base/Java.Lang/Long.cs | Deleted Java.Base-specific partial binding code. |
| src/Java.Base/Java.Lang/Integer.cs | Deleted Java.Base-specific partial binding code. |
| src/Java.Base/Java.Lang/ICharSequence.cs | Deleted Java.Base-specific partial binding code. |
| src/Java.Base/Java.Lang/Float.cs | Deleted Java.Base-specific partial binding code. |
| src/Java.Base/Java.Lang/Double.cs | Deleted Java.Base-specific partial binding code. |
| src/Java.Base/Java.Lang/Class.cs | Deleted Java.Base-specific partial binding code. |
| src/Java.Base/Java.IO/Writer.cs | Deleted Java.Base-specific partial binding code. |
| src/Java.Base/Java.IO/PrintStream.cs | Deleted Java.Base-specific partial binding code. |
| src/Java.Base/Java.Base.targets | Deleted build logic used to generate/build Java.Base bindings. |
| src/Java.Base/Java.Base.csproj | Deleted Java.Base project definition. |
| Java.Interop.sln | Removes the Java.Base project and associated solution configuration entries. |
| build-tools/Java.Interop.Sdk/Sdk/Sdk.targets | Removes Java.Base-specific reference forwarding logic from the SDK target. |
| .github/skills/build-and-test/SKILL.md | Removes Java.Base-Tests from the list of common test projects. |
| .github/copilot-instructions.md | Removes Java.Base from the documented repository structure. |
Copilot's findings
Comments suppressed due to low confidence (1)
build-tools/Java.Interop.Sdk/Sdk/Sdk.targets:156
@(_Ref, ' ')is still included in the generatorExeccommand, but_Refis no longer defined/populated anywhere in this target after removing the Java.Base special-case. This makes the command line harder to reason about and suggests a missing (or removed) feature for passing-rreferences.
<ItemGroup>
<!-- I can't find a good way to trim the trailing `\`, so append with `.` so we can sanely quote for $(_Libpath) -->
<_RefAsmDir Include="@(ReferencePathWithRefAssemblies->'%(RootDir)%(Directory).'->Distinct())" />
<_Lib Include="@(_RefAsmDir->'-L "%(Identity)"')" />
</ItemGroup>
<Exec
Command="$(DotnetToolPath) $(Generator) $(_GenFlags) $(_ApiLevel) $(_Out) @(_Lib, ' ') @(_Ref, ' ') $(_Codegen) $(_Assembly) $(_TypeMap) $(_LangFeatures) $(_Dirs) $(_Api) $(_WithJavadocXml)"
IgnoreStandardErrorWarningFormat="True"
- Files reviewed: 26/27 changed files
- Comments generated: 0
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #1447 (
remove-java-runtime-environment).Summary
Java.Basebinding assembly and generated reference API file.Java.Basefrom the solution and documentation/tooling references.Java.Basereference forwarding.Rationale
Java.Baseonly supported the standalone desktop/JRE binding path. With #1447 removingJava.Runtime.Environmentand the standalone JVM runtime surface, the in-repojava.basebinding is no longer needed by the remaining Java.Interop or dotnet/android-focused workflows.Validation
dotnet build -t:Preparedotnet build src/Java.Interop/Java.Interop.csproj --no-restoredotnet build tests/Java.Interop-Tests/Java.Interop-Tests.csproj --no-restoredotnet build tests/generator-Tests/generator-Tests.csproj --no-restoredotnet test tests/Java.Interop-Tests/Java.Interop-Tests.csproj --no-build— 669 passed, 0 failed, 4 skippeddotnet build Java.Interop.slnstill hits the same local baseline failures seen on #1447: NativeTiming CMake compiler probe (ld: library 'c++' not found) andXamarin.Android.Tools.Bytecode-TestsGradle/Kotlin setup. NoJava.Base-related build errors surfaced.