main: Add Frameworks to library paths for macOS
This commit is contained in:
17
src/main.cpp
17
src/main.cpp
@@ -192,9 +192,20 @@ int main(int argc, char *argv[]) {
|
|||||||
|
|
||||||
QGuiApplication::setWindowIcon(IconLoader::Load("strawberry"));
|
QGuiApplication::setWindowIcon(IconLoader::Load("strawberry"));
|
||||||
|
|
||||||
#if defined(USE_BUNDLE) && (defined(Q_OS_LINUX) || defined(Q_OS_MACOS))
|
#if defined(USE_BUNDLE)
|
||||||
qLog(Debug) << "Looking for resources in" << QCoreApplication::applicationDirPath() + "/" + USE_BUNDLE_DIR;
|
{
|
||||||
QCoreApplication::setLibraryPaths(QStringList() << QCoreApplication::applicationDirPath() + "/" + USE_BUNDLE_DIR);
|
QStringList library_paths;
|
||||||
|
#ifdef Q_OS_MACOS
|
||||||
|
library_paths.append(QCoreApplication::applicationDirPath() + "/../Frameworks");
|
||||||
|
#endif
|
||||||
|
#if defined(Q_OS_LINUX) || defined(Q_OS_MACOS)
|
||||||
|
library_paths.append(QCoreApplication::applicationDirPath() + "/" + USE_BUNDLE_DIR);
|
||||||
|
#endif
|
||||||
|
if (!library_paths.isEmpty()) {
|
||||||
|
qLog(Debug) << "Looking for resources in" << library_paths;
|
||||||
|
QCoreApplication::setLibraryPaths(library_paths);
|
||||||
|
}
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// Gnome on Ubuntu has menu icons disabled by default. I think that's a bad idea, and makes some menus in Strawberry look confusing.
|
// Gnome on Ubuntu has menu icons disabled by default. I think that's a bad idea, and makes some menus in Strawberry look confusing.
|
||||||
|
|||||||
Reference in New Issue
Block a user