Skip to content

Build all possible platforms with Gradle 9 - #4276

Open
taranovegor wants to merge 6 commits into
webbukkit:v3.0-community-editionfrom
taranovegor:feat/gradle-9
Open

taranovegor wants to merge 6 commits into
webbukkit:v3.0-community-editionfrom
taranovegor:feat/gradle-9

Conversation

@taranovegor

Copy link
Copy Markdown

This is the first part of #4262, as Jacob suggested: only the Gradle 9 upgrade and build changes. There is no 26.x support and no new block rendering here.

What changed:

  • Gradle wrapper is now 9.5.1. The shadow plugin is now com.gradleup.shadow.
  • Deprecated Gradle API calls are updated in all modules. The spigot build config is updated too.
  • Forge 1.17.1 to 1.21.11 now use ForgeGradle 7. In the access transformer files I replaced SRG names with Mojang names.
  • Forge 1.17.1, 1.18.2 and 1.19.3 need SRG names at runtime, so they use the Renamer plugin to remap the final jar. Without it, the 1.17.1 jar fails on a server with NoSuchMethodError.
  • The Gradle 8 check in settings.gradle is gone. All modules are included in one build.
  • README.md and CLAUDE.md now describe one build command: ./gradlew build.

About last commit 8ca30a0. I dropped Forge 1.12.2, 1.14.4, 1.15.2 and 1.16.5, and removed oldbuilds and oldgradle. This is a separate commit, so it is easy to revert or discuss. There's why:

  • 1.14.4 to 1.16.5 use MCP snapshot names in the code. ForgeGradle 7 gives Mojang names, so we get hundreds of compile errors. The code would need a big rewrite. Maybe there is an easier solution, but I could not find one.
  • 1.12.2 only builds with ForgeGradle 2 and Gradle 4.10.2. I did not try it on ForgeGradle 7.
  • Keeping them means keeping a second, old build setup.
  • Old releases stay available for anyone who needs these versions.

I am not ready to do the changes for these versions (1.12.2 -- 1.16.5) and test them afterwards. If someone wants to help, I am happy to accept the help. A good start would be moving the 1.14.4 to 1.16.5 code to Mojang names, then adding Renamer like for 1.17.1.

@taranovegor taranovegor self-assigned this Sep 30, 2026
@taranovegor
taranovegor requested a review from a team September 30, 2026 08:00

@jacob1 jacob1 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was able to compile it (had to download java 8 for the old forge builds still lol). Forge stuff looks right to me, and now all the build scripts for old / new forge versions look alike, always a good sign. The readme updates are also correct. I was going to point out the lack of java 25 there, but, that's not til the 26.3 support PR lol.

I tested the forge builds and they all work fine. Kind of just wanted to get setup to test forge (can't believe how unprofessional their website is). But now I'm able to test all versions of it.

Haven't tested spigot or fabric, I have the setup for those on my server. But no reason to hold up approval for it based on that.

Great job! Excellent PR, and satisfies my desire to keep PRs as focused and distinct as possible. This PR addresses all the "hard" stuff.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants