mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 04:24:07 +02:00
Set Python command to usr/local/python3
.
This commit is contained in:
parent
8e3f2d3601
commit
61ba685022
1 changed files with 9 additions and 0 deletions
|
@ -14,6 +14,7 @@
|
|||
#include <QProcess>
|
||||
|
||||
PythonInterface::PythonInterface() {
|
||||
#ifdef Q_OS_WIN
|
||||
if (QProcessEnvironment::systemEnvironment().contains("PYTHON_PATH")) {
|
||||
QString _pythonPath = QProcessEnvironment::systemEnvironment().value("PYTHON_PATH");
|
||||
if (!QFile::exists(_pythonPath + "/" + _pythonExe)) {
|
||||
|
@ -27,6 +28,14 @@ PythonInterface::PythonInterface() {
|
|||
"Please set PYTHON_PATH to directory containing the Python executable");
|
||||
exit(-1);
|
||||
}
|
||||
#elif defined Q_OS_MAC
|
||||
_pythonCommand = "/usr/local/bin/python3";
|
||||
if (!QFile::exists(_pythonCommand)) {
|
||||
QMessageBox::critical(0, "PYTHON_PATH not defined",
|
||||
"python3 not found at " + _pythonCommand);
|
||||
exit(-1);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
QString PythonInterface::getPythonCommand() {
|
||||
|
|
Loading…
Reference in a new issue