Don't try to update LWJGL 2 to 3 on arm machines.
parent
d4be1e7bdc
commit
98b87969cb
|
@ -61,8 +61,14 @@ public class LWJGLVersionOverride {
|
||||||
/**
|
/**
|
||||||
* Update lwjgl by default when running on arm and a supported configuration.
|
* Update lwjgl by default when running on arm and a supported configuration.
|
||||||
*/
|
*/
|
||||||
public static boolean overrideByDefault() {
|
public static boolean overrideByDefault(MinecraftVersionMeta versionMeta) {
|
||||||
return NATIVE_CLASSIFIER != null && Architecture.CURRENT.isArm();
|
if (NATIVE_CLASSIFIER == null || !Architecture.CURRENT.isArm()) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
return versionMeta.libraries().stream()
|
||||||
|
.map(MinecraftVersionMeta.Library::name)
|
||||||
|
.anyMatch(s -> s.startsWith("org.lwjgl:lwjgl:3"));
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean forceOverride(Project project) {
|
public static boolean forceOverride(Project project) {
|
||||||
|
|
|
@ -46,7 +46,7 @@ public class MinecraftLibraryProvider {
|
||||||
final BundleMetadata serverBundleMetadata = minecraftProvider.getServerBundleMetadata();
|
final BundleMetadata serverBundleMetadata = minecraftProvider.getServerBundleMetadata();
|
||||||
final boolean runtimeOnlyLog4j = extension.getRuntimeOnlyLog4j().get();
|
final boolean runtimeOnlyLog4j = extension.getRuntimeOnlyLog4j().get();
|
||||||
|
|
||||||
final boolean overrideLWJGL = LWJGLVersionOverride.overrideByDefault() || LWJGLVersionOverride.forceOverride(project) || Boolean.getBoolean("loom.test.lwjgloverride");
|
final boolean overrideLWJGL = LWJGLVersionOverride.overrideByDefault(versionInfo) || LWJGLVersionOverride.forceOverride(project) || Boolean.getBoolean("loom.test.lwjgloverride");
|
||||||
final boolean isMacOS = OperatingSystem.CURRENT_OS.equals(OperatingSystem.MAC_OS);
|
final boolean isMacOS = OperatingSystem.CURRENT_OS.equals(OperatingSystem.MAC_OS);
|
||||||
|
|
||||||
if (overrideLWJGL) {
|
if (overrideLWJGL) {
|
||||||
|
|
Loading…
Reference in New Issue