<br>On Thu, Apr 22, 2010 at 1:13 PM, Marko Kocić <span dir="ltr"><<a href="mailto:marko.kocic@gmail.com">marko.kocic@gmail.com</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">

I see that ECL itself includes both low-level clines c-inline and UFFI<br>
approach, and that CFFI also supports ECL. What are performance<br>
limitations when dealing with different bindings approaches.<br></blockquote><div><br>I do not know the status of the current CFFI backend. Last time I saw it allowed both to use a backedn based on c-inline and a backend based on the dynamic foreign function interface -- but unfortunately the only way to choose was to remove :dffi from the features --.  I find it is a good starting point because it does not have that many dependencies (alexandria, babel and trivial-features) and it may be easier to get something up and running. Besides, you may find some time to improve the backend? ;-)<br>

 </div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
I'm mainly interested in SDL right now. I would like to avoid<br>
lispbuilder-sdl because of long dependency chain (and it doesn't<br>
compile with ECL right now)</blockquote><div><br>Yes, I say the report. I will look into it.<br> </div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">

and to create low level bindings, since I<br>
would like to learn more about SDL in the process. Since app I have in<br>
plan is a small one, I'd also like to avoid CFFI as it also has long<br>
list of dependencies unless there is compelling reason to use it<br>
instead of UFFI/FFI.<br></blockquote><div><br>I cannot argue against this: direct use of ECL's FFI will produce much leaner code, not depending on an existing CFFI library -- it would be interesting to get CFFI produce standalone code: that is code that does not depend on CFFI being there to run.<br>

 </div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
Also, is there a way to automatically generate FFI bindings by<br>
providing h file, or it has to be done manually?<br clear="all"></blockquote><div><br>Not right now, but it should not be difficult to get the output of cffi-grovel and automatically translate it to ECL's FFI. <br></div>

</div><br>Juanjo<br><br>-- <br>Instituto de Física Fundamental, CSIC<br>c/ Serrano, 113b, Madrid 28006 (Spain) <br><a href="http://tream.dreamhosters.com">http://tream.dreamhosters.com</a><br>