diff options
author | Miodrag Milanovic <mmicko@gmail.com> | 2018-06-23 14:32:18 +0200 |
---|---|---|
committer | Miodrag Milanovic <mmicko@gmail.com> | 2018-06-23 14:32:49 +0200 |
commit | 82ec1be31f2a13bca04cf1a6b69789c9cee0e535 (patch) | |
tree | fed19ab35ad400d2642da1c4a327d89b0ff90f36 /gui | |
parent | b63fdfbeab5abb390c5c2c7b069672c9c8e06c82 (diff) | |
download | nextpnr-82ec1be31f2a13bca04cf1a6b69789c9cee0e535.tar.gz nextpnr-82ec1be31f2a13bca04cf1a6b69789c9cee0e535.tar.bz2 nextpnr-82ec1be31f2a13bca04cf1a6b69789c9cee0e535.zip |
Added BUILD_GUI, BUILD_PYTHON and BUILD_TESTS cmake options,
Diffstat (limited to 'gui')
-rw-r--r-- | gui/basewindow.cc | 5 | ||||
-rw-r--r-- | gui/designwidget.cc | 1 | ||||
-rw-r--r-- | gui/pythontab.cc | 3 | ||||
-rw-r--r-- | gui/pythontab.h | 3 |
4 files changed, 11 insertions, 1 deletions
diff --git a/gui/basewindow.cc b/gui/basewindow.cc index ac28e95f..9d99152c 100644 --- a/gui/basewindow.cc +++ b/gui/basewindow.cc @@ -27,7 +27,10 @@ #include "jsonparse.h"
#include "log.h"
#include "mainwindow.h"
+
+#ifndef NO_PYTHON
#include "pythontab.h"
+#endif
static void initBasenameResource() { Q_INIT_RESOURCE(base); }
@@ -70,7 +73,9 @@ BaseMainWindow::BaseMainWindow(Context *_ctx, QWidget *parent) SLOT(writeInfo(std::string)));
tabWidget = new QTabWidget();
+#ifndef NO_PYTHON
tabWidget->addTab(new PythonTab(), "Python");
+#endif
info = new InfoTab();
tabWidget->addTab(info, "Info");
diff --git a/gui/designwidget.cc b/gui/designwidget.cc index 95b76d81..6752b780 100644 --- a/gui/designwidget.cc +++ b/gui/designwidget.cc @@ -24,7 +24,6 @@ #include <QSplitter>
#include <QTreeWidgetItem>
#include "fpgaviewwidget.h"
-#include "pybindings.h"
NEXTPNR_NAMESPACE_BEGIN
diff --git a/gui/pythontab.cc b/gui/pythontab.cc index a11059b5..8e8b7be4 100644 --- a/gui/pythontab.cc +++ b/gui/pythontab.cc @@ -16,6 +16,7 @@ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
*/
+ #ifndef NO_PYTHON
#include "pythontab.h"
#include <QGridLayout>
@@ -138,3 +139,5 @@ void PythonTab::showContextMenu(const QPoint &pt) void PythonTab::clearBuffer() { plainTextEdit->clear(); }
NEXTPNR_NAMESPACE_END
+
+#endif
\ No newline at end of file diff --git a/gui/pythontab.h b/gui/pythontab.h index f37381d7..40de0ebe 100644 --- a/gui/pythontab.h +++ b/gui/pythontab.h @@ -20,6 +20,8 @@ #ifndef PYTHONTAB_H
#define PYTHONTAB_H
+#ifndef NO_PYTHON
+
#include <QLineEdit>
#include <QMenu>
#include <QPlainTextEdit>
@@ -52,5 +54,6 @@ class PythonTab : public QWidget };
NEXTPNR_NAMESPACE_END
+#endif // NO_PYTHON
#endif // PYTHONTAB_H
|