[scilab-Users] matlab (.m headers + .mexw64) to scilab ?

Laurent Alebarde l.alebarde at free.fr
Tue Sep 21 17:08:02 CEST 2010


 Le 21/09/2010 11:33, Collette yann a écrit :
> convert all the C mexfunctions into scilab C gateway functions
Thanks a lot. The svn tip were particularly usefull. I assume I have to
use the function : *ilib_mex_build *?

After download, I changed the scilab current directory to where the .c
files are located and tried :

ilib_mex_build('libta',['ta_willr','TA_WILLR','cmex'],[],['/usr/include/ta-lib/ta_libc.h'],[],'-L/usr/lib64/','','');

I get the *error* :
------------------------------------------------------------------------------------------------------------------------------------
   Génère un fichier gateway
   Génère un fichier loader
   Génère un Makefile
   ilib_gen_Make : Copie les fichiers de compilation (Makefile*,
libtool...) vers TMPDIR
   ilib_gen_Make : Copie libta.c vers TMPDIR
   ilib_gen_Make : Copie TA_WILLR.c vers TMPDIR
   ilib_gen_Make : configure : Génère le Makefile.
   ilib_gen_Make : Modification du Makefile dans TMPDIR.
   Exécute le makefile
ilib_compile: Une erreur a été detectée lors de la compilation
 
!TA_WILLR.c:1:22: error: ta_libc.h: No such file or
directory                !
!                                                                           
!
!TA_WILLR.c: In function
'mex_TA_WILLR':                                     !
!                                                                           
!
!TA_WILLR.c:46: error: 'TA_RetCode' undeclared (first use in this
function)  !
!                                                                           
!
!TA_WILLR.c:46: error: (Each undeclared identifier is reported only
once     !
!                                                                           
!
!TA_WILLR.c:46: error: for each function it appears
in.)                     !
!                                                                           
!
!TA_WILLR.c:46: error: expected ';' before
'retCode'                         !
!                                                                           
!
!TA_WILLR.c:87: error: 'retCode' undeclared (first use in this
function)     !
!                                                                           
!
!make: *** [TA_WILLR.lo] Erreur
1                                            !

ilib_compile : La commande était :
make  CFLAGS="-I/usr/share/scilab//../../include/scilab/ 
-DmexFunction=mex_$* "
CXXFLAGS="-I/usr/share/scilab//../../include/scilab/ 
-DmexFunction=mex_$* " LDFLAGS="-L/usr/lib64/"
FFLAGS="-I/usr/share/scilab//../../include/scilab/  -Dmexfunction=mex$* "
   Génère un fichier cleaner
 ------------------------------------------------------------------------------------------------------------------------------------------------------------

Obviously, I don't use the call parameters correctly. But the
documentation here :
http://www.scilab.org/product/man/ilib_mex_build.html is not enough
informative for me.

My TA lib is like this :
 ------------------------------------------------------------------------------------------------------------------------------------------------------------
* Contents of sci-libs/ta-lib-0.4.0:
/usr
/usr/bin
/usr/bin/ta-lib-config
/usr/include
/usr/include/ta-lib
/usr/include/ta-lib/ta_abstract.h
/usr/include/ta-lib/ta_common.h
/usr/include/ta-lib/ta_defs.h
/usr/include/ta-lib/ta_func.h
/usr/include/ta-lib/ta_libc.h
/usr/lib64
/usr/lib64/libta_lib.a
/usr/lib64/libta_lib.la
/usr/lib64/libta_lib.so -> libta_lib.so.0.0.0
/usr/lib64/libta_lib.so.0 -> libta_lib.so.0.0.0
/usr/lib64/libta_lib.so.0.0.0
 ------------------------------------------------------------------------------------------------------------------------------------------------------------

*Could you help or explain me which parameters I have to set and how
please ?*

Regards,

Laurent.





-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.scilab.org/pipermail/users/attachments/20100921/99d04f1a/attachment.htm>


More information about the users mailing list