Fix Fabric repo; Fix OpenAL

This commit is contained in:
khanhduytran0 2020-09-18 12:09:00 +07:00
parent feb2eff4c3
commit 09dc4c39d0
3 changed files with 5 additions and 1 deletions

View File

@ -19,6 +19,8 @@ public class JREUtils
dlopen(Tools.homeJreDir + "/lib/libawt.so"); dlopen(Tools.homeJreDir + "/lib/libawt.so");
dlopen(Tools.homeJreDir + "/lib/libawt_headless.so"); dlopen(Tools.homeJreDir + "/lib/libawt_headless.so");
dlopen("libopenal.so");
if (!dlopen(LauncherPreferences.PREF_CUSTOM_OPENGL_LIBNAME)) { if (!dlopen(LauncherPreferences.PREF_CUSTOM_OPENGL_LIBNAME)) {
System.err.println("Failed to load custom OpenGL library " + LauncherPreferences.PREF_CUSTOM_OPENGL_LIBNAME + ". Fallbacking to GL4ES."); System.err.println("Failed to load custom OpenGL library " + LauncherPreferences.PREF_CUSTOM_OPENGL_LIBNAME + ". Fallbacking to GL4ES.");
dlopen("libgl04es.so"); dlopen("libgl04es.so");

View File

@ -553,7 +553,7 @@ public class MCLauncherActivity extends AppCompatActivity
if (libItem.downloads == null || libItem.downloads.artifact == null) { if (libItem.downloads == null || libItem.downloads.artifact == null) {
MinecraftLibraryArtifact artifact = new MinecraftLibraryArtifact(); MinecraftLibraryArtifact artifact = new MinecraftLibraryArtifact();
artifact.url = "https://libraries.minecraft.net/" + libArtifact; artifact.url = (libItem.url == null ? "https://libraries.minecraft.net/" : libItem.url) + libArtifact;
libItem.downloads = new DependentLibrary.LibraryDownloads(artifact); libItem.downloads = new DependentLibrary.LibraryDownloads(artifact);
skipIfFailed = true; skipIfFailed = true;
@ -570,6 +570,7 @@ public class MCLauncherActivity extends AppCompatActivity
throw th; throw th;
} else { } else {
th.printStackTrace(); th.printStackTrace();
publishProgress("0", th.getMessage());
} }
} }
} }

View File

@ -3,6 +3,7 @@ package net.kdt.pojavlaunch.value;
public class DependentLibrary { public class DependentLibrary {
public String name; public String name;
public LibraryDownloads downloads; public LibraryDownloads downloads;
public String url;
public static class LibraryDownloads public static class LibraryDownloads
{ {