[ome-users] MATLAB/perl connector problem

YangBin (杨彬) yangbin at nlsde.buaa.edu.cn
Sat Nov 8 14:43:45 GMT 2008


I meets a problem about MATLAB/perl connector. I have installed the MATLAB 7.0.4.352(R14) and run 
[paul at imagegroup ~]$ matlab -nojvm -nodisplay
the MATLAB is run successfully.
But when I test the MATLAB/perl connector as the http://lists.openmicroscopy.org.uk/pipermail/ome-users/2005-August/000142.html, I meets a big problem.  
--------------------------------------------------------
[root at imagegroup Matlab]# make clean
rm -f \
          *.a core \
          core.[0-9] blib/arch/auto/OME/Matlab/extralibs.all \
          core.[0-9][0-9] Matlab.bso \
          pm_to_blib.ts core.[0-9][0-9][0-9][0-9] \
          Matlab.x Matlab.bs \
          Matlab.c perl \
          tmon.out *.o \
          pm_to_blib blib/arch/auto/OME/Matlab/extralibs.ld \
          blibdirs.ts core.[0-9][0-9][0-9][0-9][0-9] \
          *perl.core core.*perl.*.? \
          Makefile.aperl perl \
          Matlab.def core.[0-9][0-9][0-9] \
          mon.out libMatlab.def \
          perlmain.c perl.exe \
          so_locations Matlab.exp 
rm -rf \
          ../blib blib 
mv Makefile Makefile.old > /dev/null 2>&1
[root at imagegroup Matlab]# perl Makefile.PL 
cmd-line parameters -lib and -include must be specified. 
e.g: perl Makefile.pl -lib='-L/Applications/MATLAB704/bin/mac -lmx -leng -lut -lmat -licudata -licui18n -licuuc -lustdio -lz' -include='-I/Applications/MATLAB704/extern/include'
[root at imagegroup Matlab]# perl Makefile.pl -lib='-L/usr/local/MatLab/bin/glnx86 -lmx -leng -lut -lmat -licudata -licui18n -licuuc -lustdio -lz' -include='-I/usr/local/MatLab/extern/include'
Can't open perl script "Makefile.pl": No such file or directory
[root at imagegroup Matlab]# perl Makefile.PL -lib='-L/usr/local/MatLab/bin/glnx86 -lmx -leng -lut -lmat -licudata -licui18n -licuuc -lustdio -lz' -include='-I/usr/local/MatLab/extern/include'
define is -DPRE_73

Checking if your kit is complete...
Looks good
Modifying LD_RUN_PATH...
Modifying LD_LIBRARY_PATH...
Writing Makefile for OME::Matlab
[root at imagegroup Matlab]# make
cp Matlab.pm blib/lib/OME/Matlab.pm
cp Compiled.pm blib/lib/OME/Compiled.pm
cp compileDynamicLibraries.pl blib/lib/OME/compileDynamicLibraries.pl
cp writeLibraryPackage.pl blib/lib/OME/writeLibraryPackage.pl
/usr/bin/perl /usr/lib/perl5/5.8.8/ExtUtils/xsubpp  -typemap /usr/lib/perl5/5.8.8/ExtUtils/typemap -typemap typemap  Matlab.xs > Matlab.xsc && mv Matlab.xsc Matlab.c
Please specify prototyping behavior for Matlab.xs (see perlxs manual)
gcc -c  -I/usr/local/MatLab/extern/include -D_REENTRANT -D_GNU_SOURCE -fno-strict-aliasing -pipe -Wdeclaration-after-statement -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables   -DVERSION=\"2.0061\" -DXS_VERSION=\"2.0061\" -fPIC "-I/usr/lib/perl5/5.8.8/i386-linux-thread-multi/CORE"  -DPRE_73 Matlab.c
Matlab.xs: In function ‘XS_OME__Matlab__Array_newNumericScalar’:
Matlab.xs:222: warning: ISO C90 forbids mixed declarations and code
Matlab.c:451: warning: unused variable ‘package’
Matlab.c: In function ‘XS_OME__Matlab__Array_newLogicalScalar’:
Matlab.c:530: warning: unused variable ‘package’
Matlab.c: In function ‘XS_OME__Matlab__Array_newStringScalar’:
Matlab.c:550: warning: unused variable ‘package’
Matlab.c: In function ‘XS_OME__Matlab__Array_newDoubleMatrix’:
Matlab.c:570: warning: unused variable ‘package’
Matlab.c: In function ‘XS_OME__Matlab__Array_newLogicalMatrix’:
Matlab.c:598: warning: unused variable ‘package’
Matlab.c: In function ‘XS_OME__Matlab__Array_newNumericMatrix’:
Matlab.c:619: warning: unused variable ‘package’
Matlab.c: In function ‘XS_OME__Matlab__Array_newStructMatrix’:
Matlab.c:654: warning: unused variable ‘package’
Matlab.c: In function ‘XS_OME__Matlab__Array_newLogicalArray’:
Matlab.c:706: warning: unused variable ‘package’
Matlab.c: In function ‘XS_OME__Matlab__Array_newStringArray’:
Matlab.c:736: warning: unused variable ‘package’
Matlab.c: In function ‘XS_OME__Matlab__Array_newNumericArray’:
Matlab.c:785: warning: unused variable ‘package’
Matlab.xs: In function ‘XS_OME__Matlab__Array_dimensions’:
Matlab.xs:480: warning: ISO C90 forbids mixed declarations and code
Matlab.xs: In function ‘XS_OME__Matlab__Array_getString’:
Matlab.xs:644: warning: ISO C90 forbids mixed declarations and code
Matlab.xs: In function ‘XS_OME__Matlab__Array_get’:
Matlab.xs:658: warning: ISO C90 forbids mixed declarations and code
Matlab.xs: In function ‘XS_OME__Matlab__Array_set’:
Matlab.xs:731: warning: ISO C90 forbids mixed declarations and code
Matlab.xs: In function ‘XS_OME__Matlab__Array_getAll’:
Matlab.xs:815: warning: ISO C90 forbids mixed declarations and code
Matlab.xs: In function ‘XS_OME__Matlab__Array_setAll’:
Matlab.xs:874: warning: ISO C90 forbids mixed declarations and code
Matlab.xs:896: warning: format ‘%d’ expects type ‘int’, but argument 2 has type ‘I32’
Matlab.c: In function ‘XS_OME__Matlab__Engine_open’:
Matlab.c:2107: warning: unused variable ‘package’
Running Mkbootstrap for OME::Matlab ()
chmod 644 Matlab.bs
rm -f blib/arch/auto/OME/Matlab/Matlab.so
gcc  -shared -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -L/usr/local/lib Matlab.o  -o blib/arch/auto/OME/Matlab/Matlab.so     \
           -L/usr/local/MatLab/bin/glnx86 -lmx -leng -lut -lmat -licudata -licui18n -licuuc -lustdio -lz -L/usr/local/lib       \
          
chmod 755 blib/arch/auto/OME/Matlab/Matlab.so
cp Matlab.bs blib/arch/auto/OME/Matlab/Matlab.bs
chmod 644 blib/arch/auto/OME/Matlab/Matlab.bs
Manifying blib/man3/OME::Matlab.3pm
[root at imagegroup Matlab]# make test
PERL_DL_NONLAZY=1 LD_LIBRARY_PATH=/usr/local/MatLab/bin/glnx86 DYLD_LIBRARY_PATH=/usr/local/MatLab/bin/glnx86 /usr/bin/perl "-Iblib/lib" "-Iblib/arch" test.pl
Trying to compute 4x8 using MATLAB ...
Test Failed.
 Perl Matlab API is incorrectly installed.
The MATLAB engine does not start.
make: *** [test_dynamic] Error 255
[root at imagegroup Matlab]# 

I have no idea about why the test is fail. 
Does anyone help me ? Very Thanks.


 				
--------------
Best Regards,

Paul Yang

Email : yangbin at nlsde.buaa.edu.cn

School of Computer Science and Engneering, Beihang University
Beijing 100191, P.R. China

2008-11-08


More information about the ome-users mailing list