comparison src/hgrunner.cpp @ 699:646e48a0d3a5

Some work on macOS packaging
author Chris Cannam
date Tue, 11 Dec 2018 16:40:57 +0000
parents 7194ca023517
children 07c610b06e58
comparison
equal deleted inserted replaced
698:52b8a499f379 699:646e48a0d3a5
26 #include <QTemporaryFile> 26 #include <QTemporaryFile>
27 #include <QDir> 27 #include <QDir>
28 #include <QProgressBar> 28 #include <QProgressBar>
29 #include <QPushButton> 29 #include <QPushButton>
30 #include <QGridLayout> 30 #include <QGridLayout>
31 #include <QCoreApplication>
31 32
32 #include <iostream> 33 #include <iostream>
33 #include <errno.h> 34 #include <errno.h>
34 #include <stdio.h> 35 #include <stdio.h>
35 #include <stdlib.h> 36 #include <stdlib.h>
42 #include <process.h> 43 #include <process.h>
43 #endif 44 #endif
44 45
45 HgRunner::HgRunner(QString myDirPath, QWidget *parent) : 46 HgRunner::HgRunner(QString myDirPath, QWidget *parent) :
46 QWidget(parent), 47 QWidget(parent),
47 m_myDirPath(myDirPath), 48 m_ptyFile(0),
48 m_ptyFile(0) 49 m_proc(0),
50 m_myDirPath(myDirPath)
49 { 51 {
50 QGridLayout *layout = new QGridLayout(this); 52 QGridLayout *layout = new QGridLayout(this);
51 layout->setMargin(0); 53 layout->setMargin(0);
52 54
53 m_progress = new QProgressBar; 55 m_progress = new QProgressBar;
584 586
585 #ifdef Q_OS_MAC 587 #ifdef Q_OS_MAC
586 if (QSettings().value("python32", false).toBool()) { 588 if (QSettings().value("python32", false).toBool()) {
587 env.insert("VERSIONER_PYTHON_PREFER_32_BIT", "1"); 589 env.insert("VERSIONER_PYTHON_PREFER_32_BIT", "1");
588 } 590 }
591 QDir pluginDir(QCoreApplication::applicationDirPath());
592 pluginDir.cd("../plugins");
593 env.insert("QT_PLUGIN_PATH", pluginDir.canonicalPath());
589 #endif 594 #endif
590 595
591 env.insert("LANG", "en_US.utf8"); 596 env.insert("LANG", "en_US.utf8");
592 env.insert("LC_ALL", "en_US.utf8"); 597 env.insert("LC_ALL", "en_US.utf8");
593 env.insert("HGENCODING", "utf8"); 598 env.insert("HGENCODING", "utf8");