octave-3.0.1 building on ubuntu/gutsy - intel x32
John W. Eaton
jwe at bevo.che.wisc.edu
Wed Aug 20 10:49:27 CDT 2008
On 18-Aug-2008, Jaroslav Hajek wrote:
| Apparently "news" doesn't work when octave is not installed. Please
| just read the NEWS file in your octave-3.0.1 directory. I'll check
| what is wrong.
The news function does this:
datadir = octave_config_info ("datadir");
newsfile = fullfile (datadir, "octave", version (), "NEWS");
if (exist (newsfile, "file"))
f = fopen (newsfile, "r");
while (ischar (line = fgets (f)))
printf (line);
endwhile
else
error ("news: unable to locate NEWS file");
endif
I suppose we could also look for the NEWS file in $abs_top_srcdir.
That variable is not currently stored in octave_config_info, but it is
available in Makeconf.in, so we could we could put it there without
too much effort. However, I'm not sure that making this change is
really worth doing.
Running Octave from the build directory is really only intended to
work for testing purposes, and I don't see that it is really necessary
for the news function to work in that case. You are really expected
to install Octave to be able to use it. If you are running from the
build directory, then surely you can find the NEWS file without
needing the news function at the Octave prompt?
jwe
More information about the Bug-octave
mailing list