aboutsummaryrefslogtreecommitdiff
path: root/launcher/Application.cpp
diff options
context:
space:
mode:
authorTrial97 <alexandru.tripon97@gmail.com>2023-08-17 17:29:57 +0300
committerTrial97 <alexandru.tripon97@gmail.com>2023-08-17 17:29:57 +0300
commitc5bac475e86ec1c4e0053bd330eabedcbca124f6 (patch)
treec2be43dac099f5b98b9dbaaeb1244b7efeb01a58 /launcher/Application.cpp
parent4a1d85f99913d0bacf8cdd118c81401378c758b6 (diff)
parente88418ab7f1a2979ccb1ef92b4cd7da87f5cd6c5 (diff)
downloadPrismLauncher-c5bac475e86ec1c4e0053bd330eabedcbca124f6.tar.gz
PrismLauncher-c5bac475e86ec1c4e0053bd330eabedcbca124f6.tar.bz2
PrismLauncher-c5bac475e86ec1c4e0053bd330eabedcbca124f6.zip
Merge branch 'develop' of https://github.com/PrismLauncher/PrismLauncher into develop
Diffstat (limited to 'launcher/Application.cpp')
-rw-r--r--launcher/Application.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/launcher/Application.cpp b/launcher/Application.cpp
index 4da41142..78de8747 100644
--- a/launcher/Application.cpp
+++ b/launcher/Application.cpp
@@ -585,7 +585,9 @@ Application::Application(int& argc, char** argv) : QApplication(argc, argv)
// Native library workarounds
m_settings->registerSetting("UseNativeOpenAL", false);
+ m_settings->registerSetting("CustomOpenALPath", "");
m_settings->registerSetting("UseNativeGLFW", false);
+ m_settings->registerSetting("CustomGLFWPath", "");
// Peformance related options
m_settings->registerSetting("EnableFeralGamemode", false);
@@ -845,6 +847,8 @@ Application::Application(int& argc, char** argv) : QApplication(argc, argv)
updateCapabilities();
+ detectLibraries();
+
if (createSetupWizard()) {
return;
}
@@ -1415,6 +1419,15 @@ void Application::updateCapabilities()
#endif
}
+void Application::detectLibraries()
+{
+#ifdef Q_OS_LINUX
+ m_detectedGLFWPath = MangoHud::findLibrary(BuildConfig.GLFW_LIBRARY_NAME);
+ m_detectedOpenALPath = MangoHud::findLibrary(BuildConfig.OPENAL_LIBRARY_NAME);
+ qDebug() << "Detected native libraries:" << m_detectedGLFWPath << m_detectedOpenALPath;
+#endif
+}
+
QString Application::getJarPath(QString jarFile)
{
QStringList potentialPaths = {