How use a custom library in a toolbox ?
Vincent Lejeune
vincent.lejeune at institutoptique.fr
Sun May 3 22:42:21 CEST 2009
Hello,
I'd like to make a toolbox for Scilab with source that need to be compiled
with nvcc , which is not considered as a common compiler (it makes asm code
from cuda source).
I made a .lib file containing precompiled functions I liked to use within
the gateway part from the squeleton toolbox. That means, I add a #pragma
comment(lib,"...") pointing to the .lib file, and the header containing the
prototype of my functions. However, the automated script doesnt work, here
is the output (in french sorry, only the end does matter anyway) :
> Initialisation:
> Chargement de l'environnement de travail
> Génère un fichier loader
> Génère un Makefile
> Exécute le Makefile
> Compilation de csum.c
> Compilation de csub.c
> Construction de la bibliothèque partagée (soyez patient)
> NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual
> Studio 9.0\VC\bin\link.EXE"'á: code retour '0x450'
> Stop.
> !--error 10000
> unix_s: error during "nmake /Y /nologo /f Makelib.mak libcsum.dll"
> execution
> at line 34 of function unix_s called by :
> line 50 of function ilib_compile called by :
> line 34 of function ilib_for_link called by :
> line 18 of function tbx_build_src called by :
> _absolute_file_path('builder_c.sce'))
> line 9 of exec file called by :
> ktop/TOOLBO~1/src/c/BUILDE~1.SCE'));
I'm under windows. It's seems that the linking is failling. How can I embed
function inside a .lib in a gateway function ? I think it's possible, as
other part of Scilab's source code contains code writed in fortran...But
without the builder script.
More information about the dev
mailing list