Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
freebsd
GitHub Repository: freebsd/freebsd-ports-kde
Path: blob/main/astro/indiwebmanagerapp/files/patch-src_mainwindow.cpp
16461 views
1
--- src/mainwindow.cpp 2022-05-22 01:43:45.247103000 -0500
2
+++ src/mainwindow.cpp 2022-05-22 01:50:16.014480000 -0500
3
@@ -295,6 +295,8 @@
4
#ifdef Q_OS_OSX
5
//Note this is the Path where python3 gets symlinked by homebrew.
6
return "/usr/local/opt/python/libexec/bin";
7
+ #elif defined(Q_OS_FREEBSD)
8
+ return "%%LOCALBASE%%/bin";
9
#endif
10
if (flat.isEmpty() == false)
11
return flat + "/bin/";
12
@@ -307,6 +309,8 @@
13
{
14
#ifdef Q_OS_OSX
15
return "/usr/local/bin/indi-web";
16
+ #elif defined(Q_OS_FREEBSD)
17
+ return "%%LOCALBASE%%/bin/indi-web";
18
#endif
19
return QDir::homePath() + "/.local/bin/indi-web";
20
}
21
@@ -316,6 +320,8 @@
22
{
23
#ifdef Q_OS_OSX
24
return QStandardPaths::locate(QStandardPaths::GenericDataLocation, QString(), QStandardPaths::LocateDirectory) + "INDIWebManagerApp/gsc";
25
+ #elif defined(Q_OS_FREEBSD)
26
+ return "%%LOCALBASE%%/share/gsc";
27
#endif
28
if (flat.isEmpty() == false)
29
return flat + "/share/GSC";
30
@@ -329,6 +335,8 @@
31
#ifdef Q_OS_OSX
32
QString appPath = QCoreApplication::applicationDirPath();
33
return QDir(appPath + "/../../").absolutePath();
34
+ #elif defined(Q_OS_FREEBSD)
35
+ return "%%LOCALBASE%%/bin/";
36
#endif
37
return "";
38
}
39
@@ -338,6 +346,8 @@
40
{
41
#ifdef Q_OS_OSX
42
return QDir(QCoreApplication::applicationDirPath()).absolutePath();
43
+ #elif defined(Q_OS_FREEBSD)
44
+ return "%%LOCALBASE%%/bin/";
45
#endif
46
if (flat.isEmpty() == false)
47
return flat + "/bin/";
48
@@ -351,6 +361,8 @@
49
#ifdef Q_OS_OSX
50
QString appPath = QCoreApplication::applicationDirPath();
51
return QDir(appPath + "/../Resources/DriverSupport").absolutePath();
52
+ #elif defined(Q_OS_FREEBSD)
53
+ return "%%LOCALBASE%%/share/indi";
54
#elif defined(Q_OS_LINUX)
55
if (flat.isEmpty() == false)
56
return flat + "/share/indi";
57
@@ -543,7 +555,6 @@
58
*/
59
bool MainWindow::pythonInstalled(QString pythonExecFolder)
60
{
61
-
62
return QFileInfo(pythonExecFolder + "/python").exists() || QFileInfo(pythonExecFolder + "/python2").exists() || QFileInfo(pythonExecFolder + "/python3").exists();
63
}
64
65
66