Mercurial > hg > tony
comparison src/main.cpp @ 458:60779173dddf
Win32 build updates; version is 1.0
author | Chris Cannam |
---|---|
date | Wed, 01 Apr 2015 12:59:34 +0100 |
parents | ea7ca3335a1a |
children | 7665cc683dd1 |
comparison
equal
deleted
inserted
replaced
453:a2d7e5f75bac | 458:60779173dddf |
---|---|
37 #include <QFileOpenEvent> | 37 #include <QFileOpenEvent> |
38 #include <QDir> | 38 #include <QDir> |
39 | 39 |
40 #include <iostream> | 40 #include <iostream> |
41 #include <signal.h> | 41 #include <signal.h> |
42 #include <cstdlib> | |
42 | 43 |
43 #include <vamp-hostsdk/PluginHostAdapter.h> | 44 #include <vamp-hostsdk/PluginHostAdapter.h> |
44 | 45 |
45 static QMutex cleanupMutex; | 46 static QMutex cleanupMutex; |
46 static bool cleanedUp = false; | 47 static bool cleanedUp = false; |
151 for (auto p: vampPathList) qVampPathList.push_back(p.c_str()); | 152 for (auto p: vampPathList) qVampPathList.push_back(p.c_str()); |
152 QString vampPath = qVampPathList.join(sep); | 153 QString vampPath = qVampPathList.join(sep); |
153 QString newPath = tonyVampPath + sep + vampPath; | 154 QString newPath = tonyVampPath + sep + vampPath; |
154 | 155 |
155 cerr << "Setting VAMP_PATH to " << newPath << " for Tony plugins" << endl; | 156 cerr << "Setting VAMP_PATH to " << newPath << " for Tony plugins" << endl; |
156 | 157 |
157 setenv("VAMP_PATH", newPath.toLocal8Bit().data(), 1); | 158 QString env = "VAMP_PATH=" + newPath; |
159 | |
160 // Windows lacks setenv, must use putenv (different arg convention) | |
161 putenv(strdup(env.toLocal8Bit().data())); | |
158 } | 162 } |
159 | 163 |
160 int | 164 int |
161 main(int argc, char **argv) | 165 main(int argc, char **argv) |
162 { | 166 { |