kinit: don't use obsolete macros in library paths patch
This commit is contained in:
parent
9f00e2be18
commit
18f95ce5d9
@ -1,8 +1,8 @@
|
|||||||
Index: kinit-5.24.0/src/kdeinit/kinit.cpp
|
Index: kinit-5.32.0/src/kdeinit/kinit.cpp
|
||||||
===================================================================
|
===================================================================
|
||||||
--- kinit-5.24.0.orig/src/kdeinit/kinit.cpp
|
--- kinit-5.32.0.orig/src/kdeinit/kinit.cpp
|
||||||
+++ kinit-5.24.0/src/kdeinit/kinit.cpp
|
+++ kinit-5.32.0/src/kdeinit/kinit.cpp
|
||||||
@@ -672,19 +672,16 @@ static pid_t launch(int argc, const char
|
@@ -623,19 +623,15 @@ static pid_t launch(int argc, const char
|
||||||
|
|
||||||
if (!libpath.isEmpty()) {
|
if (!libpath.isEmpty()) {
|
||||||
if (libpath_relative) {
|
if (libpath_relative) {
|
||||||
@ -23,10 +23,9 @@ Index: kinit-5.24.0/src/kdeinit/kinit.cpp
|
|||||||
+ QByteArrayList profiles = qgetenv("NIX_PROFILES").split(' ');
|
+ QByteArrayList profiles = qgetenv("NIX_PROFILES").split(' ');
|
||||||
+ // Reverse the profile list.
|
+ // Reverse the profile list.
|
||||||
+ std::reverse(profiles.begin(), profiles.end());
|
+ std::reverse(profiles.begin(), profiles.end());
|
||||||
+ const QString libdir = QString::fromLatin1("/lib/");
|
+ for (const QByteArray &profile: profiles) {
|
||||||
+ Q_FOREACH (const QByteArray &profile, profiles) {
|
|
||||||
+ if (!profile.isEmpty()) {
|
+ if (!profile.isEmpty()) {
|
||||||
+ l.setFileName(QFile::decodeName(profile) + libdir + libpath);
|
+ l.setFileName(QFile::decodeName(profile) + QStringLiteral("/lib/") + libpath);
|
||||||
+ if (l.load()) break;
|
+ if (l.load()) break;
|
||||||
+ }
|
+ }
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user