Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[2.x] Fix analysis of Java compilation to jar #1371

Closed
wants to merge 4 commits into from

Conversation

adpi2
Copy link
Member

@adpi2 adpi2 commented Jul 3, 2024

The goal of this PR is to fix the java-mixed test with straight-to-JAR compilation enabled. The difficulty here was to remap class files from the previous JAR (Scala compilation) to class files in the output JAR.

But most of the PR is a refactoring of JavaAnalyze to reduce nesting and parameter passing.

This will be needed by sbt/sbt#7592

@adpi2 adpi2 changed the title Fix analysis of Java compilation to jar [2.x] Fix analysis of Java compilation to jar Jul 3, 2024
adpi2 added 2 commits July 3, 2024 16:35
- JavaClassFileMapper: to map classFile from temp folder to output jar
- CachedClassLoader: to cache loading classes and class files
- JavaAnalyzer: to compute the dependency analysis
@adpi2 adpi2 force-pushed the 2.x-compile-straight-to-jar branch from 346e86b to 54ceb43 Compare July 4, 2024 12:20
@adpi2 adpi2 marked this pull request as ready for review July 4, 2024 14:19
@adpi2 adpi2 requested a review from eed3si9n July 4, 2024 14:19
@adpi2 adpi2 marked this pull request as draft July 4, 2024 15:27
@adpi2
Copy link
Member Author

adpi2 commented Jul 4, 2024

Actually I have the same or similar issue with JavaThenScala so I am going to fix it too.

@adpi2
Copy link
Member Author

adpi2 commented Jul 8, 2024

Superseded by #1376

@adpi2 adpi2 closed this Jul 8, 2024
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant