help-octave
[Top][All Lists]
Advanced

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

Re: Debug loading of oct-file


From: John W. Eaton
Subject: Re: Debug loading of oct-file
Date: Mon, 07 Jan 2008 13:03:48 -0500

On  7-Jan-2008, Kim Hansen wrote:

| On Jan 7, 2008 5:47 PM, John W. Eaton <address@hidden> wrote:
| >
| > On  7-Jan-2008, Kim Hansen wrote:
| >
| > | I have problems getting octave to load an oct-file I have build with a
| > | test installation of octave:
| > |
| > | I am building the octave installation and runs octave like this:
| > | ===
| > | address@hidden:~/saft-octave/solver/saft/octave/ignore$ ls -l
| > | total 6
| > | drwxr-xr-x 14 kim kim 4096 2008-01-06 20:20 cvs     # Updated cvs
| > | checkout of octave
| > | drwxr-xr-x  2 kim kim   25 2008-01-07 17:17 my_code   # My code
| > |
| > | mkdir build
| > | cd build
| > | ../cvs/configure F77=gfortran --prefix=$(readlink -f ../install)
| > | make check install
| > | cd ..
| > |
| > | cd my_code
| > | # build my code ...
| > | ../install/bin/octave
| > |
| > | octave:1> coin_oct
| > | error: `coin_oct' undefined near line 1 column 1
| > | octave:1> ls -l coin_oct.oct
| > | -rwxr-xr-x 1 kim kim 1756418 2008-01-07 17:17 coin_oct.oct
| > | octave:2>
| > | ===
| > |
| > | How do I start debugging what the problem is ?
| > |
| > | I have tried to load my code into an old version of octave (2.9.15),
| > | and that gives me the expected error message:
| > | ===
| > | octave:1> coin_oct
| > | error: API version api-v32+ found in .oct file function `coin_oct'
| > |        does not match the running Octave (API version api-v27)
| > |        this can lead to incorrect results or other failures
| > |        you can fix this problem by recompiling this .oct file
| > | error: failed to install .oct file function `coin_oct'
| >
| > It looks like your copy of octave installed in your ../install
| > directory is linking to an older version of the Octave libraries
| > (liboctinterp, liboctave, libcruft) when it starts.
| >
| 
| I don't think that is the case:
| ====
| address@hidden:~/saft-octave/solver/saft/octave/ignore/my_code$ ldd
| ../install/bin/octave
|       linux-gate.so.1 =>  (0xffffe000)
|       liboctinterp.so =>
| 
/home/kim/saft-octave/solver/saft/octave/ignore/install/lib/octave-3.0.0+/liboctinterp.so
| (0xb75eb000)
|       liboctave.so =>
| 
/home/kim/saft-octave/solver/saft/octave/ignore/install/lib/octave-3.0.0+/liboctave.so
| (0xb6d74000)
|       libcruft.so =>
| 
/home/kim/saft-octave/solver/saft/octave/ignore/install/lib/octave-3.0.0+/libcruft.so
| (0xb6d27000)
|       libumfpack.so.1 => /usr/lib/libumfpack.so.1 (0xb6c6f000)
|       libamd.so.1 => /usr/lib/libamd.so.1 (0xb6c67000)

Then some other

| I remember something about a variable I could set in octave and then
| it would show how it tries to load function files, but I can't find
| anything about it now. Can anyone give a hint about what that
| functionality might be called?

I don't think that would help, as it seems that a current version of
the .oct file is being loaded (api-v32+ corresponds to Octave version
3.0.0+).  The error message is telling you that the api version in the
.oct file doesn't match the one that was compiled into Octave
(actually liboctinterp.so).  So it appears that somehow that library
picked up the wrong copy of version.h when it was compiled, or it was
not completely recompiled correctly when you updated.  Did you build
from scratch or update your cvs sources from an old copy?  Is all of the
dependency information in the generated .d files up to date?  What
does

  strings src/pic/defun.o | grep api

print?

jwe


reply via email to

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