I tried just a tad bit more. Maybe it doesn't make any sense, I don't know, but I tried popen2 instead of popen. Still it doesn't work, but it fails silently and the handle is not -1. On the other hand experimenting with the scripts, I stumbled on yet something else. There is a code in __gnuplot_version__.m:
[status, output] = system (sprintf ("%s --version", gnuplot_binary ()));
This seems to work under linux (Fedora 8, octave 2.9.15), but in windows, it gives an error:
octave:1> [status, output] = system (sprintf ("%s --version", gnuplot_binary ()));
error: value on right hand side of assignment is undefined
error: evaluating assignment _expression_ near line 1, column 19
Since it pointed to a c++ function (system, in this case), I stopped there, as I'm not sure exactly what I need to compile octave in windows (and how painful it will be, though should be OK once you set things up).
Kind regards,
Nusret
----- Original Message ----
From: Michael Goffioul <address@hidden>
To: N. B. <address@hidden>
Cc: address@hidden
Sent: Monday, December 17, 2007 7:08:34 AM
Subject: Re: problem with gnuplot and octave, 2.9.19, MSVC build on windows XP
On 12/17/07, N. B. <
address@hidden> wrote:
>
>
> Then it invokes gnuplot (the one included with octave: I removed my other
> version to save space and confusion), but octave seems to have no control
> until I quit the gnuplot. Namely, I cannot use octave syntax until I type
> quit in gnuplot prompt and fall back to the octave prompt.
This is normal. I just wanted to check whether gnuplot was available.
Normally, octave starts gnuplot
using something like:
h = popen("pgnuplot");
pclose(h);
If this works correctly, then I don't see any other way to find the problem
than debugging drawnow.m to see what's exactly executed and trying to
see what's going on.
Michael.