[Ecls-list] UFFI:LOAD-FOREIGN-LIBRARY

dan at sof.ch dan at sof.ch
Mon Nov 14 10:19:04 UTC 2005


> ...
> Please complain if it does not work as expected :-)
> 
> Juanjo

Sorry, but it does not... =<8-(

The problem is that it does not check wether the file exists or not...


(defun do-load-foreign-library (tmp)
  (let* ((filename (namestring (compile-file-pathname tmp :type :lib)))
----------------------------------------------------------------^^^^
  ...

On my system (linux/intel), 

(compile-file-pathname #P"/usr/lib/libSDL.so" :type :lib)

does return:

#P"/usr/lib/liblibSDL.a"

and this is NOT what I expected. (Does it have any sense ?)

When I give a full path to an existing file, I expect the system will
link precisely this file.

Anyway, guessing is ok when specification is incomplete. I wont say anything
if ECL tries to load /usr/lib/libSDL.a when I write:

(load-foreign-library "libSDL") or (load-foreign-library "SDL")

except that it should at least try to determine if the file exists,
because the compilation will fail anyway otherwise.

Sorry...

Have fun...

-- 
Courage, fuyons...




More information about the ecl-devel mailing list