Mercurial > hg > svcore
diff base/HelperExecPath.cpp @ 1694:a9d0b5a2c242 single-point
Also look for helpers in Resources folder on the Mac
author | Chris Cannam |
---|---|
date | Thu, 25 Apr 2019 15:55:51 +0100 |
parents | 75aefcc9f07d |
children | 008e413f6aaf |
line wrap: on
line diff
--- a/base/HelperExecPath.cpp Thu Apr 25 11:30:51 2019 +0100 +++ b/base/HelperExecPath.cpp Thu Apr 25 15:55:51 2019 +0100 @@ -58,9 +58,17 @@ QStringList HelperExecPath::getHelperDirPaths() { + // Helpers are expected to exist either in the same directory as + // this executable was found, or in either a subdirectory called + // helpers, or on the Mac only, a sibling called Resources. + QStringList dirs; QString myDir = QCoreApplication::applicationDirPath(); +#ifdef Q_OS_MAC + dirs.push_back(myDir + "/../Resources"); +#else dirs.push_back(myDir + "/helpers"); +#endif dirs.push_back(myDir); return dirs; } @@ -76,9 +84,6 @@ QList<HelperExecPath::HelperExec> HelperExecPath::search(QString basename, QStringList &candidates) { - // Helpers are expected to exist either in the same directory as - // this executable was found, or in a subdirectory called helpers. - QString extension = ""; #ifdef _WIN32 extension = ".exe";