Adopted from NixOS
pkgs/development/libraries/kde-frameworks/kio/samba-search-path.patch
===================================================================
--- kio-5.17.0.orig/src/core/ksambashare.cpp
+++ kio-5.17.0/src/core/ksambashare.cpp
@@ -67,13 +67,18 @@ KSambaSharePrivate::~KSambaSharePrivate(
bool KSambaSharePrivate::isSambaInstalled()
{
- if (QFile::exists(QStringLiteral("/usr/sbin/smbd"))
- || QFile::exists(QStringLiteral("/usr/local/sbin/smbd"))) {
- return true;
+ const QByteArray pathEnv = qgetenv("PATH");
+ if (!pathEnv.isEmpty()) {
+ QLatin1Char pathSep(':');
+ QStringList paths = QFile::decodeName(pathEnv).split(pathSep, QString::SkipEmptyParts);
+ for (QStringList::iterator it = paths.begin(); it != paths.end(); ++it) {
+ it->append(QStringLiteral("/smbd"));
+ if (QFile::exists(*it)) {
+ return true;
+ }
+ }
}
- //qDebug() << "Samba is not installed!";
-
return false;
}
td>
aboutsummaryrefslogtreecommitdiff
|
Age | Commit message (Expand) | Author |
2024-06-26 | etc: Add explicit ‘--substitute-urls’ in guix-daemon service files....Having substitute URLs explicitly listed in the service startup file
makes it clearer what should be modified to permanently change the list
of substitute URLs.
* config-daemon.ac: Rename ‘guix_substitute_urls’ to
‘GUIX_SUBSTITUTE_URLS’ and substitute it.
* nix/local.mk (etc/guix-%.service, etc/init.d/guix-daemon)
(etc/guix-%.conf): Substitute it.
* etc/guix-daemon.conf.in, etc/guix-daemon.service.in,
etc/init.d/guix-daemon.in: Add an explicit ‘--substitute-urls’ option.
Change-Id: Ie491b7fab5c42e54dca582801c03805a85de2bf9
| Ludovic Courtès |
2024-03-11 | etc: systemd services: switch to "journal" for output and error logging....The "syslog" method has been deprecated for years, and issues a warning:
Standard output type syslog is obsolete, automatically updating to
journal. Please update your unit file, and consider removing the setting
altogether.
Fixes: #48323
* etc/guix-daemon.service.in (StandardOutput): Use "journal"
(StandardError): Likewise.
* etc/guix-publish.service.in (StandardOutput): Likewise.
(StandardError): Likewise.
| Vagrant Cascadian |
2022-10-23 | etc: systemd services shouldn't ‘RemainAfterExit’....* etc/guix-daemon.service.in (RemainAfterExit): Don't.
* etc/guix-publish.service.in (RemainAfterExit): Likewise don't.
| Tobias Geerinckx-Rice |
2022-10-23 | etc: Add ‘Restart=always’ to both systemd services....* etc/guix-daemon.service.in (Restart): ‘Always’ do.
* etc/guix-publish.service.in (Restart): Likewise.
| Tobias Geerinckx-Rice |
2022-10-23 | etc: Add ‘OOMPolicy=continue’ to guix-daemon.service....* etc/guix-daemon.service.in (OOMPolicy): Continue.
| Tobias Geerinckx-Rice |