help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Errors from matrix.h when using mkoctfile


From: John Seales
Subject: Errors from matrix.h when using mkoctfile
Date: Tue, 27 Aug 2013 15:41:52 -0700

Octave version 3.6.2
Mac OS 10.7.5


I'm trying to use the Harmonic Progression Analyzer, which was written for Matlab. Very helpfully, the authors have included the C source for the a mex file that the program uses, which I've attached. 

Attachment: HPSS_innerLoop.c
Description: Binary data


I've tried to make a mex file with mckoctfile, and haven't been successful. I'm hoping someone can get me on the right track. Thanks in advance. 

At the bottom of the email is the mkoctfile command I tried, and the errors generated. To me it looks like C code that is part of Octave itself is trying (and failing) to use C++ code. 

Line 45, the offending line of HPSS_innerloop.c, reads: #include "matrix.h"

Any advice or pointers in the right general direction will be greatly appreciated. 

octave:10> mkoctfile -mex 'HPSS_innerloop.c'
In file included from HPSS_innerloop.c:45:
In file included from /usr/local/Cellar/octave/3.6.2/include/octave-3.6.2/octave/matrix.h:30:
In file included from /usr/local/Cellar/octave/3.6.2/include/octave-3.6.2/octave/mx-base.h:28:
/usr/local/Cellar/octave/3.6.2/include/octave-3.6.2/octave/MatrixType.h:27:1: error: 
      unknown type name 'class'
class Matrix;
^
/usr/local/Cellar/octave/3.6.2/include/octave-3.6.2/octave/MatrixType.h:28:1: error: 
      unknown type name 'class'
class ComplexMatrix;
^
/usr/local/Cellar/octave/3.6.2/include/octave-3.6.2/octave/MatrixType.h:29:1: error: 
      unknown type name 'class'
class FloatMatrix;
^
/usr/local/Cellar/octave/3.6.2/include/octave-3.6.2/octave/MatrixType.h:30:1: error: 
      unknown type name 'class'
class FloatComplexMatrix;
^
/usr/local/Cellar/octave/3.6.2/include/octave-3.6.2/octave/MatrixType.h:31:1: error: 
      unknown type name 'class'
class SparseMatrix;
^
/usr/local/Cellar/octave/3.6.2/include/octave-3.6.2/octave/MatrixType.h:32:1: error: 
      unknown type name 'class'
class SparseComplexMatrix;
^
/usr/local/Cellar/octave/3.6.2/include/octave-3.6.2/octave/MatrixType.h:34:1: error: 
      unknown type name 'class'
class
^
/usr/local/Cellar/octave/3.6.2/include/octave-3.6.2/octave/MatrixType.h:35:11: error: 
      expected ';' after top level declarator
OCTAVE_API
          ^
          ;
In file included from HPSS_innerloop.c:45:
In file included from /usr/local/Cellar/octave/3.6.2/include/octave-3.6.2/octave/matrix.h:30:
In file included from /usr/local/Cellar/octave/3.6.2/include/octave-3.6.2/octave/mx-base.h:32:
In file included from /usr/local/Cellar/octave/3.6.2/include/octave-3.6.2/octave/boolMatrix.h:27:
/usr/local/Cellar/octave/3.6.2/include/octave-3.6.2/octave/Array.h:29:10: fatal error: 
      'cassert' file not found
#include <cassert>
         ^
9 errors generated.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]