|
"Eric " <ec29740@gmail.com> wrote in message
<fuqgft$e07$1@fred.mathworks.com>...
> I have been unable to reproduce the solution proposed in this thread. I am
> running 2008a on leopard. I copied and pasted the testmex.f file given
above.
> It compiles fine with no error or warning, see below. Running testmex with
no
> argument works -- running it with an argument makes matlab crash, same
> symptoms as listed previously on this thread. Any idea what might be
> causing this?
>
> Note that when I use g95 instead of gfortran I get this warning:
> ld: warning, duplicate dylib
> /Applications/MATLAB_R2008a/bin/maci/libz.1.dylib
>
> but the behavior of testmex is the same -- works with no argument,
crashes
> Matlab when run with an argument.
>
> Any help or hint would be appreciated!
> Eric
>
> ==== CRASH MESSAGE =====
> >> testmex(2)
> dyld: lazy symbol binding failed: Symbol not found:
> _mxgetnumberofelements_
> Referenced from: /Users/Eric/Junk/testmex.mexmaci
> Expected in: flat namespace
>
> dyld: Symbol not found: _mxgetnumberofelements_
> Referenced from: /Users/Eric/Junk/testmex.mexmaci
> Expected in: flat namespace
>
> Trace/BPT trap
I suspect the case of mxgetnumberofelements called from your test code is
wrong. Please verify that the code is either all uppercase all lowercase or the
specified CamelCase.
(1) MXGETNUMBEROFELEMENTS
(2) mxgetnumberofelements
(3) mxGetNumberOfElements
If the case of any character deviates from those, the error you received will
result. This particular feature is due to a change that occurred in 2007.
If you are interested in the details, see the c-preprocessor stuff in
/Applications/MATLAB_2008a/extern/include/fintrf.h
Ben
|