[Scilab-users] Importing FMU generated by Xcos (Scilab)
Clément David
clement.david at scilab-enterprises.com
Mon Apr 13 15:00:12 CEST 2015
Hello Michele,
As you already write, the FMU generated by the module depends on the
simulation functions shipped with Scilab.
Xcos simulation functions are shipped in two flavor :
* libsciscicos_blocks.so
depends on a full Scilab
you have to link with blas / lapack, the whole Scilab binaries, the
JVM libs and so on
* libsciscicos_blocks-cli.so
only depends on Scilab non-GUI
just link with blas / lapack and the some of the scilab internal libs
I suggest you to only link against libsciscicos_blocks-cli as this is
will ship an FMU with minimal dependency (only minimal Scilab).
A third approach (and the most independent one) is to retrieve and
compile the scicos_blocks C / Fortran sources directly from Scilab
source code without linking against Scilab libs. However you have to
take care by yourself of any licensing issue.
Regards,
--
Clément
Le lundi 13 avril 2015 à 02:14 -0700, mfabbri a écrit :
> I haven't found a solution yet, but I got some progress.
>
> I tried to re-generate the .so file inside the FMU (using the source inside
> the FMU). The error changed at every time that I added a new library to the
> linker, and so I added all the libraries of SciLab (/usr/lib/scilab/*).
>
> The error depends also on how I generate the .so file.
>
> gcc -Wl,--no-as-needed -fPIC -shared -o prova.so prova_Scilab_FMU.c
> /usr/lib/scilab/* -I/usr/include/scilab/
> -I/home/mfabbri/.Scilab/fmu-wrapper-0.6/src/c/
> You can check the output of the FMUChecker and of the command ldd -d
> here: http://pastebin.com/qBLiDRgd
> As you can see, I have a problem with JAVA library (Java is installed in
> my OS). I tried to linked that library but without success.
>
> while using this same commmand without the "Wl,--no-as-needed" flag: gcc
> -fPIC -shared -o prova.so prova_Scilab_FMU.c /usr/lib/scilab/*
> -I/usr/include/scilab/ -I/home/mfabbri/.Scilab/fmu-wrapper-0.6/src/c/
> You can check the output of the FMUChecker and of the command ldd -d
> here: http://pastebin.com/MaV2pdHT
> I know that the "undefined symbol: pvApiCtx" is in api_common.h
> (/usr/include/scilab) file but I didn't find the library to link.
>
> More, in both solutions there is this string in the FMUChecker output:
> [INFO][FMILIB] Loading 'linux64' binary with 'standard32' platform types
> Is normal this info? I'm using Linux Mint 17.1 Rebecca - 64bit
>
> For now I'm stuck for both the solutions but what I want to try is to link
> all the libraries in the OS.
>
> Thank you to everybody that wants to help me
>
>
>
> --
> View this message in context: http://mailinglists.scilab.org/Importing-FMU-generated-by-Xcos-Scilab-tp4032046p4032075.html
> Sent from the Scilab users - Mailing Lists Archives mailing list archive at Nabble.com.
> _______________________________________________
> users mailing list
> users at lists.scilab.org
> http://lists.scilab.org/mailman/listinfo/users
More information about the users
mailing list