Automatically generate nb-javac from JDK sources#12
Open
JaroslavTulach wants to merge 29 commits intooracle:masterfrom
Open
Automatically generate nb-javac from JDK sources#12JaroslavTulach wants to merge 29 commits intooracle:masterfrom
JaroslavTulach wants to merge 29 commits intooracle:masterfrom
Conversation
added 19 commits
January 20, 2021 04:44
0d09dcf to
60e817e
Compare
JaroslavTulach
commented
Mar 8, 2021
JaroslavTulach
commented
Mar 8, 2021
JaroslavTulach
commented
Mar 8, 2021
5fa0f8d to
39be830
Compare
|
I can confirm that this builds fine with JDK 14.0.2, and I've uploaded the bits for testing. https://oss.sonatype.org/content/repositories/comdukescript-1139/com/dukescript/nbjavac/nb-javac/ |
|
The build works fine with JDK 14.0.2, and the staged bits are available here: |
|
this is pretty cool. How comes that this didn't make it in yet? |
|
@JaroslavTulach : does this also work with JDK 17 or only JDK 14 ? |
lahodaj
pushed a commit
to lahodaj/nb-javac
that referenced
this pull request
Dec 9, 2024
upgrade javac dependency to 19.0.1.
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.
The nb-javac overview proposal suggests to minimize differences between JDK's
javacandnb-javacby automatically applying advanced refactorings and thus making sure thejavacfrom recent JDK can run on JDK8. This PR is implementation of that idea.The best part of this PR is the deletion of more than
230 000lines of code, that are no longer needed to be maintained. Rather than that the build script starts by checking out a JDK repository (currently at revisionJDK-16+36). Thesrc/java.compilerandsrc.jdk.compilersources are then massaged to use only JDK8 APIs using advanced refactorings transformations. As a result of that thenb-javacsources can link against JDK8+ APIs.The next step is to take the code and compile the source to JDK8's bytecode. Once finished, the outcome remains the same: two JAR files in the
make/langtools/netbeans/nb-javac/dist/folder. Those can be used and tested with any JDK8+.