From 2b5d3d4a3a7ba5d1fcc85e890267157faa09291b Mon Sep 17 00:00:00 2001 From: modmuss50 Date: Wed, 28 Jul 2021 18:19:56 +0100 Subject: [PATCH] Revert: "Always fork the java compiler" Fixes #453 This reverts 0cfa88f73b7b6da200dc5bac3dde3884a854e17f as it causes OOM issues when building fabric api. --- .../fabricmc/loom/configuration/CompileConfiguration.java | 6 ------ 1 file changed, 6 deletions(-) diff --git a/src/main/java/net/fabricmc/loom/configuration/CompileConfiguration.java b/src/main/java/net/fabricmc/loom/configuration/CompileConfiguration.java index 579f51f..549447a 100644 --- a/src/main/java/net/fabricmc/loom/configuration/CompileConfiguration.java +++ b/src/main/java/net/fabricmc/loom/configuration/CompileConfiguration.java @@ -29,7 +29,6 @@ import org.gradle.api.artifacts.ConfigurationContainer; import org.gradle.api.plugins.JavaPlugin; import org.gradle.api.plugins.JavaPluginConvention; import org.gradle.api.tasks.SourceSet; -import org.gradle.api.tasks.compile.JavaCompile; import org.gradle.api.tasks.javadoc.Javadoc; import org.gradle.jvm.tasks.Jar; @@ -107,11 +106,6 @@ public final class CompileConfiguration { Javadoc javadoc = (Javadoc) p.getTasks().getByName(JavaPlugin.JAVADOC_TASK_NAME); javadoc.setClasspath(main.getOutput().plus(main.getCompileClasspath())); - p.getTasks().withType(JavaCompile.class).configureEach(compile -> { - // Fork the java compiler to ensure that it does not keep any files open. - compile.getOptions().setFork(true); - }); - p.afterEvaluate(project -> { LoomGradleExtension extension = LoomGradleExtension.get(project);