20 GetModuleFileName(
NULL, buf, 256);
21 for (i=strlen(buf); i >= 0 && buf[
i] !=
'\\'; --
i) {;}
23 for (i=strlen(buf); i >= 0 && buf[
i] !=
'\\'; --
i) {;}
25 nrnhome =
new char[strlen(buf)+1];
36 for (i=1; i <
argc; ++
i) {
37 cnt += strlen(argv[i]) + 20;
41 for (i=1; i <
argc; ++
i) {
47 for (a = u; *a; ++a) {
71 ShowWindow(GetConsoleWindow(), SW_HIDE);
76 buf =
new char[strlen(args) + 6*strlen(
nh) + 200];
85 sprintf(buf,
"%s\\mingw\\usr\\bin\\bash.exe -i %s/lib/neuron3.sh %s nrngui %s",
nrnhome,
nh,
nh, args);
88 sprintf(buf,
"%s\\bin\\mintty -c %s/lib/minttyrc %s/bin/bash --rcfile %s/lib/nrnstart.bsh %s/lib/neuron.sh %s %s",
nrnhome,
nh,
nh,
nh,
nh,
nh, args);
90 msg =
new char[strlen(buf) + 100];
91 err = WinExec(buf, SW_SHOW);
93 sprintf(msg,
"Cannot WinExec %s\n", buf);
94 MessageBox(0, msg,
"NEURON", MB_OK);
char * hoc_dos2unixpath(const char *d)
sprintf(buf," if (secondorder) {\ " int _i;\" " for(_i=0;_i< %d;++_i) {\" " _p[_slist%d[_i]]+=dt *_p[_dlist%d[_i]];\" " }}\", numeqn, listnum, listnum)
int main(int argc, char **argv)
static void setneuronhome()
static char * argstr(int argc, char **argv)