mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 04:44:11 +02:00
Booboo...
This commit is contained in:
parent
716bd8ebd2
commit
1c7c0dd0a0
1 changed files with 13 additions and 0 deletions
|
@ -14,6 +14,19 @@
|
|||
#include <QProcess>
|
||||
|
||||
PythonInterface::PythonInterface() {
|
||||
if (QProcessEnvironment::systemEnvironment().contains("PYTHON_PATH")) {
|
||||
QString _pythonPath = QProcessEnvironment::systemEnvironment().value("PYTHON_PATH");
|
||||
if (!QFile::exists(_pythonPath + "/" + _pythonExe)) {
|
||||
QMessageBox::critical(0, _pythonExe, QString("Python executable not found in ") + _pythonPath);
|
||||
exit(-1);
|
||||
}
|
||||
|
||||
_pythonCommand = _pythonPath + "/" + _pythonExe;
|
||||
} else {
|
||||
QMessageBox::critical(0, "PYTHON_PATH not defined",
|
||||
"Please set PYTHON_PATH to directory containing the Python executable");
|
||||
exit(-1);
|
||||
}
|
||||
}
|
||||
|
||||
QString PythonInterface::getPythonCommand() {
|
||||
|
|
Loading…
Reference in a new issue