[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Octave modules and Mac OS X/Darwin
From: |
Pierre G |
Subject: |
Octave modules and Mac OS X/Darwin |
Date: |
Mon, 15 Nov 2004 07:36:58 -0500 |
Hello.
I installed Octave on Mac OS X (10.3.6).
I tried to create a module written in C++ for octave but this only
results in errors.
I followed step by step the 'hello.cc' example of the following web
page :
http://perso.wanadoo.fr/prthomas/intro.html
So here is my file :
// beginning of hello.cc
#include <octave/oct.h>
DEFUN_DLD (hello, args, , "[...] = hello (...)\nPrint Hello World\n.")
{
octave_value retval;
octave_stdout << "Hello world!\n";
return retval = 42.0;
}
//end of hello.cc
and this is the command I type in octave with the displayed errors :
//--------- beginning of octave
octave:1> system('mkoctfile hello.cc')
In file included from /sw/include/octave-2.1.53/octave/ov-base.h:39,
from /sw/include/octave-2.1.53/octave/ov-fcn.h:36,
from /sw/include/octave-2.1.53/octave/ov-builtin.h:32,
from /sw/include/octave-2.1.53/octave/defun-int.h:28,
from /sw/include/octave-2.1.53/octave/defun-dld.h:30,
from /sw/include/octave-2.1.53/octave/oct.h:35,
from hello.cc:1:
/sw/include/octave-2.1.53/octave/ov.h:37:18: hdf5.h: No such file or
directory
In file included from /sw/include/octave-2.1.53/octave/ov-base.h:39,
from /sw/include/octave-2.1.53/octave/ov-fcn.h:36,
from /sw/include/octave-2.1.53/octave/ov-builtin.h:32,
from /sw/include/octave-2.1.53/octave/defun-int.h:28,
from /sw/include/octave-2.1.53/octave/defun-dld.h:30,
from /sw/include/octave-2.1.53/octave/oct.h:35,
from hello.cc:1:
/sw/include/octave-2.1.53/octave/ov.h:666: error: `hid_t' was not
declared in
this scope
/sw/include/octave-2.1.53/octave/ov.h:666: error: parse error before
`,' token
/sw/include/octave-2.1.53/octave/ov.h:669: error: `hid_t' was not
declared in
this scope
/sw/include/octave-2.1.53/octave/ov.h:669: error: parse error before
`,' token
/sw/include/octave-2.1.53/octave/ov.h: In member function `virtual bool
octave_value::save_hdf5(...)':
/sw/include/octave-2.1.53/octave/ov.h:667: error: `loc_id' undeclared
(first
use this function)
/sw/include/octave-2.1.53/octave/ov.h:667: error: (Each undeclared
identifier
is reported only once for each function it appears in.)
/sw/include/octave-2.1.53/octave/ov.h:667: error: `name' undeclared
(first use
this function)
/sw/include/octave-2.1.53/octave/ov.h:667: error: `save_as_floats'
undeclared
(first use this function)
/sw/include/octave-2.1.53/octave/ov.h: In member function `virtual bool
octave_value::load_hdf5(...)':
/sw/include/octave-2.1.53/octave/ov.h:671: error: `have_h5giterate_bug'
undeclared (first use this function)
In file included from /sw/include/octave-2.1.53/octave/ov-fcn.h:36,
from /sw/include/octave-2.1.53/octave/ov-builtin.h:32,
from /sw/include/octave-2.1.53/octave/defun-int.h:28,
from /sw/include/octave-2.1.53/octave/defun-dld.h:30,
from /sw/include/octave-2.1.53/octave/oct.h:35,
from hello.cc:1:
/sw/include/octave-2.1.53/octave/ov-base.h: At global scope:
/sw/include/octave-2.1.53/octave/ov-base.h:268: error: parse error
before `,'
token
/sw/include/octave-2.1.53/octave/ov-base.h:270: error: parse error
before `,'
token
ans = 1
octave:2>
//--------- end of octave
I don't know if I send this at the right place but I did not find who
ported octave to Mac OS X / Darwin.
I hope this will help.
Basically my question is : does anyone succeeded in compiling modules
on Mac OS X, because this looks like a bug -- error -- in the octave
include files.
Good luck and thank you if you have any suggestion,
Pierre Grabolosa.
-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.
Octave's home on the web: http://www.octave.org
How to fund new projects: http://www.octave.org/funding.html
Subscription information: http://www.octave.org/archive.html
-------------------------------------------------------------