Another attempt at fixing issues with fernflower's classpath
parent
4a30993da7
commit
d91b722c35
|
@ -100,7 +100,7 @@ public abstract class AbstractFernFlowerDecompiler implements LoomDecompiler {
|
||||||
|
|
||||||
progressGroup.started();
|
progressGroup.started();
|
||||||
ExecResult result = ForkingJavaExec.javaexec(
|
ExecResult result = ForkingJavaExec.javaexec(
|
||||||
project.getRootProject().getPlugins().hasPlugin("fabric-loom") ? project.getRootProject() : project,
|
project,
|
||||||
spec -> {
|
spec -> {
|
||||||
spec.setMain(fernFlowerExecutor().getName());
|
spec.setMain(fernFlowerExecutor().getName());
|
||||||
spec.jvmArgs("-Xms200m", "-Xmx3G");
|
spec.jvmArgs("-Xms200m", "-Xmx3G");
|
||||||
|
|
|
@ -47,15 +47,14 @@ public class ForkingJavaExec {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
private static Set<Configuration> getForkedFernflowerClasspath(Project project) {
|
private static Configuration[] getForkedFernflowerClasspath(Project project) {
|
||||||
Set<Configuration> allConfigurations = new HashSet<>();
|
Set<Configuration> allConfigurations = new HashSet<>();
|
||||||
Project p = project;
|
allConfigurations.addAll(project.getBuildscript().getConfigurations());
|
||||||
|
|
||||||
do {
|
if (project.getRootProject() != project) {
|
||||||
allConfigurations.addAll(p.getBuildscript().getConfigurations());
|
allConfigurations.addAll(project.getRootProject().getBuildscript().getConfigurations());
|
||||||
p = p.getRootProject();
|
}
|
||||||
} while (p != p.getRootProject());
|
|
||||||
|
|
||||||
return allConfigurations;
|
return allConfigurations.toArray(new Configuration[0]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue