summaryrefslogtreecommitdiff
path: root/kernel/driver.cc
diff options
context:
space:
mode:
authorClifford Wolf <clifford@clifford.at>2015-02-16 13:23:54 +0100
committerClifford Wolf <clifford@clifford.at>2015-02-16 13:23:54 +0100
commit3e5e9a38895b0ce45c185916fa946dec38ffbab3 (patch)
treebbd6ae663ac6740c437a748f82402d2dbd7ee06d /kernel/driver.cc
parent33e80b96c7aac6b93e6bee18572abf529f8cc1fa (diff)
More YosysJS stuff
Diffstat (limited to 'kernel/driver.cc')
-rw-r--r--kernel/driver.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/kernel/driver.cc b/kernel/driver.cc
index 69a7b8e1..d0ebdde7 100644
--- a/kernel/driver.cc
+++ b/kernel/driver.cc
@@ -73,6 +73,8 @@ int getopt(int argc, char **argv, const char *optstring)
USING_YOSYS_NAMESPACE
#ifdef EMSCRIPTEN
+# include <sys/stat.h>
+# include <sys/types.h>
extern "C" int main(int, char**);
extern "C" void run(const char*);
@@ -80,6 +82,8 @@ extern "C" const char *prompt();
int main(int, char**)
{
+ mkdir("/work", 0777);
+ chdir("/work");
log_files.push_back(stdout);
log_error_stderr = true;
yosys_banner();