diff -ruN kservice-5.29.0-orig/src/sycoca/kmimeassociations.cpp kservice-5.29.0/src/sycoca/kmimeassociations.cpp --- kservice-5.29.0-orig/src/sycoca/kmimeassociations.cpp 2016-12-03 15:10:37.000000000 -0600 +++ kservice-5.29.0/src/sycoca/kmimeassociations.cpp 2016-12-30 20:02:49.000000000 -0600 @@ -59,8 +59,12 @@ } mimeappsFileNames.append(QStringLiteral("mimeapps.list")); // list the dirs in the order of the spec (XDG_CONFIG_HOME, XDG_CONFIG_DIRS, XDG_DATA_HOME, XDG_DATA_DIRS) - const QStringList mimeappsDirs = QStandardPaths::standardLocations(QStandardPaths::GenericConfigLocation) + QStringList mimeappsDirs = QStandardPaths::standardLocations(QStandardPaths::GenericConfigLocation) + QStandardPaths::standardLocations(QStandardPaths::ApplicationsLocation); + mimeappsDirs.removeDuplicates(); +#ifdef Q_OS_MACOS + mimeappsDirs.removeAll(QLatin1String("/Applications")); +#endif QStringList mimeappsFiles; // collect existing files foreach (const QString &dir, mimeappsDirs) { diff -ruN kservice-5.29.0-orig/src/sycoca/vfolder_menu.cpp kservice-5.29.0/src/sycoca/vfolder_menu.cpp --- kservice-5.29.0-orig/src/sycoca/vfolder_menu.cpp 2016-12-03 15:10:37.000000000 -0600 +++ kservice-5.29.0/src/sycoca/vfolder_menu.cpp 2016-12-30 20:02:49.000000000 -0600 @@ -793,6 +793,10 @@ VFolderMenu::initDirs() { m_defaultAppDirs = QStandardPaths::standardLocations(QStandardPaths::ApplicationsLocation); +#ifdef Q_OS_MACOS + m_defaultAppDirs.removeDuplicates(); + m_defaultAppDirs.removeAll(QStringLiteral("/Applications")); +#endif m_defaultDirectoryDirs = QStandardPaths::locateAll(QStandardPaths::GenericDataLocation, QStringLiteral("desktop-directories"), QStandardPaths::LocateDirectory); }