1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-10-15 07:42:24 +00:00
serenity/Ports/qt6-qtbase/patches/0004-Hack-Force-searching-for-plugins-in-usr-local.patch

29 lines
1.2 KiB
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Martin=20B=C5=99=C3=ADza?= <m@rtinbriza.cz>
Date: Wed, 15 Dec 2021 21:09:35 +0100
Subject: [PATCH] Hack: Force searching for plugins in /usr/local
I really don't know how else to do this but I'm sure there is a proper
way to handle this. But this works and doesn't break the system so
whatever for now.
---
src/corelib/kernel/qcoreapplication.cpp | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/src/corelib/kernel/qcoreapplication.cpp b/src/corelib/kernel/qcoreapplication.cpp
index 009aa28..9c0cb52 100644
--- a/src/corelib/kernel/qcoreapplication.cpp
+++ b/src/corelib/kernel/qcoreapplication.cpp
@@ -2760,6 +2760,12 @@ QStringList QCoreApplication::libraryPathsLocked()
}
#endif // Q_OS_DARWIN
+#ifdef Q_OS_SERENITY
+ coreappdata()->app_libpaths->append("/usr/local");
+ coreappdata()->app_libpaths->append("/usr/local/lib");
+ coreappdata()->app_libpaths->append("/usr/local/plugins");
+#endif // Q_OS_SERENITY
+
QString installPathPlugins = QLibraryInfo::path(QLibraryInfo::PluginsPath);
if (QFile::exists(installPathPlugins)) {
// Make sure we convert from backslashes to slashes.