Path: blob/main/astro/indiwebmanagerapp/files/patch-src_mainwindow.cpp
16461 views
--- src/mainwindow.cpp 2022-05-22 01:43:45.247103000 -05001+++ src/mainwindow.cpp 2022-05-22 01:50:16.014480000 -05002@@ -295,6 +295,8 @@3#ifdef Q_OS_OSX4//Note this is the Path where python3 gets symlinked by homebrew.5return "/usr/local/opt/python/libexec/bin";6+ #elif defined(Q_OS_FREEBSD)7+ return "%%LOCALBASE%%/bin";8#endif9if (flat.isEmpty() == false)10return flat + "/bin/";11@@ -307,6 +309,8 @@12{13#ifdef Q_OS_OSX14return "/usr/local/bin/indi-web";15+ #elif defined(Q_OS_FREEBSD)16+ return "%%LOCALBASE%%/bin/indi-web";17#endif18return QDir::homePath() + "/.local/bin/indi-web";19}20@@ -316,6 +320,8 @@21{22#ifdef Q_OS_OSX23return QStandardPaths::locate(QStandardPaths::GenericDataLocation, QString(), QStandardPaths::LocateDirectory) + "INDIWebManagerApp/gsc";24+ #elif defined(Q_OS_FREEBSD)25+ return "%%LOCALBASE%%/share/gsc";26#endif27if (flat.isEmpty() == false)28return flat + "/share/GSC";29@@ -329,6 +335,8 @@30#ifdef Q_OS_OSX31QString appPath = QCoreApplication::applicationDirPath();32return QDir(appPath + "/../../").absolutePath();33+ #elif defined(Q_OS_FREEBSD)34+ return "%%LOCALBASE%%/bin/";35#endif36return "";37}38@@ -338,6 +346,8 @@39{40#ifdef Q_OS_OSX41return QDir(QCoreApplication::applicationDirPath()).absolutePath();42+ #elif defined(Q_OS_FREEBSD)43+ return "%%LOCALBASE%%/bin/";44#endif45if (flat.isEmpty() == false)46return flat + "/bin/";47@@ -351,6 +361,8 @@48#ifdef Q_OS_OSX49QString appPath = QCoreApplication::applicationDirPath();50return QDir(appPath + "/../Resources/DriverSupport").absolutePath();51+ #elif defined(Q_OS_FREEBSD)52+ return "%%LOCALBASE%%/share/indi";53#elif defined(Q_OS_LINUX)54if (flat.isEmpty() == false)55return flat + "/share/indi";56@@ -543,7 +555,6 @@57*/58bool MainWindow::pythonInstalled(QString pythonExecFolder)59{60-61return QFileInfo(pythonExecFolder + "/python").exists() || QFileInfo(pythonExecFolder + "/python2").exists() || QFileInfo(pythonExecFolder + "/python3").exists();62}63646566