Prerequisites
Before building Essential from source, ensure you have the required tools and dependencies installed.Required Java versions
Install the following JDK versions from Adoptium:- Java 21 (or newer) - Must be the default Java version
- Java 17
- Java 16
- Java 8
Install multiple JDK versions
Download and install all four required Java versions from Adoptium. The build system needs access to all of them.
Additional tools
No additional tools like Gradle need to be installed manually. The Gradle wrapper included in the repository will automatically download the correct Gradle version.
- Git (for cloning the repository and managing submodules)
- 16GB+ RAM (configured in
gradle.propertiesas-Xmx16G) - Fast internet connection (first build downloads many dependencies)
Cloning the repository
Clone with submodules
Option A: Clone with recursive flag (recommended)Option B: Clone then initialize submodules
Building Essential
Build all versions
To build Essential for all Minecraft versions:Depending on your system and internet connection, the first build may take 10 minutes to an hour. Subsequent builds will be much faster thanks to Gradle’s caching.
Build for specific version
To build for a specific Minecraft version and mod loader:Output files
Once the build completes, find the compiled jars in:-
pinned_*.jar- Mod file for Modrinth/CurseForge- Contains a specific version of Essential
- Larger file size
- Suitable for modpacks
-
Essential *.jar- Main mod file- Downloaded by in-game updater
- Used by third-party mods embedding Essential Loader
- Used by container mods and the Essential Installer
Building Essential Loader
The Essential Loader is automatically built when building the main mod (included inpinned_ jars).
The loader is split into three stages, each with platform-specific variants:
Platforms:
fabric- All Fabric versionslaunchwrapper- Forge on Minecraft 1.8.9 and 1.12.2modlauncher8- Forge on Minecraft 1.16.5modlauncher9- Forge on Minecraft 1.17+
For technical details about loader stages, see
loader/docs/stages.md in the repository. For platform details, see loader/docs/platforms.md.Building Essential Container
The Essential Container is a thin mod that downloads Essential on first launch.Choose your platform
Select the appropriate platform for your target:
fabric- All Fabric versionslaunchwrapper- Forge 1.8.9 and 1.12.2modlauncher8- Forge 1.16.5modlauncher9- Forge 1.17+, NeoForge
Container mods are small (< 1 MB) and download the latest Essential version at runtime, while pinned mods include a specific Essential version.
Build configuration
The build is configured in several key files:gradle.properties
Key build properties:build.gradle.kts
Main build script with:- Dependency management
- Kotlin version constraints
- Platform-specific configurations
- Relocation rules for bundled libraries
settings.gradle.kts
Defines all Minecraft version projects:Gradle wrapper
Essential includes the Gradle wrapper for reproducible builds:- Linux/macOS:
./gradlew - Windows:
gradlew.bat
Continuous Integration (CI)
Every Essential release is built by CI twice:Internal CI build
Built on ModCore’s internal, self-hosted CI system:
- Faster build times
- Runs integration tests
- Uploads jars to infrastructure
- Publishes source code to GitHub
Verifying checksums
You can verify the authenticity of Essential files:Build locally or get checksums
Option A: Build Essential yourself following the steps aboveOption B: Find the GitHub Actions run and download the
checksums artifact or view the Generate checksums logIdentify file type
Determine which file you’re verifying:
.minecraft/mods/: Container (< 1 MB) or pinned mod (larger).minecraft/essential/: Main Essential jar.minecraft/essential/loader/: Loader stage files.minecraft/essential/libraries/: Extracted dependencies
Some Essential versions are compatible with multiple Minecraft versions. See
versions/aliases.txt for the exact mapping.Common build issues
Java version errors
Java version errors
Error: Build fails with Java version errorsSolution: Ensure Java 21 is your default version:Also verify all required JDK versions (8, 16, 17, 21) are installed.
Out of memory errors
Out of memory errors
Error:
java.lang.OutOfMemoryError: Java heap spaceSolution: The build is configured for 16GB RAM in gradle.properties. If you have less RAM, reduce the value:Submodule errors
Submodule errors
Error: Missing files or build failures related to the loaderSolution: Update git submodules:
Gradle daemon issues
Gradle daemon issues
Error: Build hangs or fails mysteriouslySolution: Stop all Gradle daemons and retry:
First build takes too long
First build takes too long
This is expected. The first build:
- Downloads all Minecraft versions
- Downloads all dependencies
- Sets up development environments
- Compiles for all platforms
Development environment
To set up Essential for development in your IDE:Import the project
Import the Essential directory as a Gradle project in your IDE (IntelliJ IDEA or Eclipse).
Wait for Gradle sync
Let your IDE sync the Gradle project. This may take several minutes on first import.
License restrictions
Getting help
For build issues or development questions:- Join the Essential Discord and use the dedicated support channels
- Check existing GitHub issues for similar problems
- Review the loader documentation in
loader/docs/
Additional resources
Loader stages
See
loader/docs/stages.md for technical details about the three-stage loader architectureLoader platforms
See
loader/docs/platforms.md for details about different mod loader platformsContainer vs Pinned
See
loader/docs/container-mods.md for technical details about container and pinned mod variantsBuild logic
See
build-logic/src/main/kotlin/essential/pinned-jar.gradle.kts for how pinned jars are generated