Merge pull request #202210 from apfelkuchen6/solid

libsForQt515.solid: patch binary search paths
This commit is contained in:
K900 2023-03-10 22:51:42 +03:00 committed by GitHub
commit 0f6504938f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 19 additions and 1 deletions

View File

@ -128,7 +128,7 @@ let
oxygen-icons5 = callPackage ./oxygen-icons5.nix {};
prison = callPackage ./prison.nix {};
qqc2-desktop-style = callPackage ./qqc2-desktop-style.nix {};
solid = callPackage ./solid.nix {};
solid = callPackage ./solid {};
sonnet = callPackage ./sonnet.nix {};
syntax-highlighting = callPackage ./syntax-highlighting.nix {};
threadweaver = callPackage ./threadweaver.nix {};

View File

@ -6,6 +6,7 @@
mkDerivation {
pname = "solid";
patches = [ ./fix-search-path.patch ];
nativeBuildInputs = [ bison extra-cmake-modules flex media-player-info ];
buildInputs = [ qtdeclarative qttools ];
propagatedBuildInputs = [ qtbase ];

View File

@ -0,0 +1,17 @@
diff --git a/src/solid/devices/backends/fstab/fstabhandling.cpp b/src/solid/devices/backends/fstab/fstabhandling.cpp
index ac2a628..7ee46cc 100644
--- a/src/solid/devices/backends/fstab/fstabhandling.cpp
+++ b/src/solid/devices/backends/fstab/fstabhandling.cpp
@@ -275,7 +275,11 @@ bool Solid::Backends::Fstab::FstabHandling::callSystemCommand(const QString &com
const QObject *receiver,
std::function<void(QProcess *)> callback)
{
- static const QStringList searchPaths{QStringLiteral("/sbin"), QStringLiteral("/bin"), QStringLiteral("/usr/sbin"), QStringLiteral("/usr/bin")};
+ static const QStringList searchPaths{QStringLiteral("/run/wrappers/bin"),
+ QStringLiteral("/sbin"),
+ QStringLiteral("/bin"),
+ QStringLiteral("/usr/sbin"),
+ QStringLiteral("/usr/bin")};
static const QString joinedPaths = searchPaths.join(QLatin1Char(':'));
const QString exec = QStandardPaths::findExecutable(commandName, searchPaths);
if (exec.isEmpty()) {