aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/yosys.h
diff options
context:
space:
mode:
authorEddie Hung <eddie@fpgeh.com>2019-04-22 11:19:52 -0700
committerEddie Hung <eddie@fpgeh.com>2019-04-22 11:19:52 -0700
commit4883391b6331e62226c46e797f82a31ef9ef81a3 (patch)
tree3779d9d3c226602b96eb6f72e2c780e02c64df3e /kernel/yosys.h
parentd06d4f35c376672ad1042b46bb29d7bd2bfa5243 (diff)
parentbc98a463a433e5b1553b307301e67e641a148d3c (diff)
downloadyosys-4883391b6331e62226c46e797f82a31ef9ef81a3.tar.gz
yosys-4883391b6331e62226c46e797f82a31ef9ef81a3.tar.bz2
yosys-4883391b6331e62226c46e797f82a31ef9ef81a3.zip
Merge remote-tracking branch 'origin/master' into xaig
Diffstat (limited to 'kernel/yosys.h')
-rw-r--r--kernel/yosys.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/kernel/yosys.h b/kernel/yosys.h
index c9f973318..2cf6188b4 100644
--- a/kernel/yosys.h
+++ b/kernel/yosys.h
@@ -66,6 +66,10 @@
#include <stdio.h>
#include <limits.h>
+#ifdef WITH_PYTHON
+#include <Python.h>
+#endif
+
#ifndef _YOSYS_
# error It looks like you are trying to build Yosys without the config defines set. \
When building Yosys with a custom make system, make sure you set all the \
@@ -115,6 +119,7 @@ extern const char *Tcl_GetStringResult(Tcl_Interp *interp);
# define PATH_MAX 4096
#endif
+#define YOSYS_NAMESPACE Yosys
#define PRIVATE_NAMESPACE_BEGIN namespace {
#define PRIVATE_NAMESPACE_END }
#define YOSYS_NAMESPACE_BEGIN namespace Yosys {
@@ -276,6 +281,11 @@ namespace hashlib {
}
void yosys_setup();
+
+#ifdef WITH_PYTHON
+bool yosys_already_setup();
+#endif
+
void yosys_shutdown();
#ifdef YOSYS_ENABLE_TCL
@@ -317,6 +327,9 @@ extern std::vector<RTLIL::Design*> pushed_designs;
// from passes/cmds/pluginc.cc
extern std::map<std::string, void*> loaded_plugins;
+#ifdef WITH_PYTHON
+extern std::map<std::string, void*> loaded_python_plugins;
+#endif
extern std::map<std::string, std::string> loaded_plugin_aliases;
void load_plugin(std::string filename, std::vector<std::string> aliases);