From shark.fin.soup at mac.com Sat Sep 10 15:54:43 2005 From: shark.fin.soup at mac.com (Shark Fin Soup) Date: Sat, 10 Sep 2005 22:54:43 +0700 Subject: [cl-gd-devel] Lispworks on Mac Message-ID: <8E5DD611-D09B-45AF-9D5E-6A040FA7E20C@mac.com> With the following make file, I am receiving the following error when trying to run the test. The glue code created with this makefile has no problem running on SBCL. I am not sure what must be done to get this working on Lispworks? Makefile: cl-gd-glue.so: gcc -I/usr/local/include -I/sw/include -g -c -dynamiclib -o cl-gd-glue.o cl-gd-gl ue.c libtool -dynamic -lgd -lz -lpng -ljpeg -lfreetype -liconv - lm -lc -o cl-gd-glue.s o cl-gd-glue.o -L/usr/local/lib -L/sw/lib rm cl-gd-glue.o Lispworks Error: Error: Foreign function GD-IMAGE-CREATE trying to call to unresolved external function "gdImageCreate" Thank you, Dr. Atip Asvanund -------------- next part -------------- An HTML attachment was scrubbed... URL: From edi at agharta.de Sat Sep 10 18:23:21 2005 From: edi at agharta.de (Edi Weitz) Date: Sat, 10 Sep 2005 20:23:21 +0200 Subject: [cl-gd-devel] Lispworks on Mac In-Reply-To: <8E5DD611-D09B-45AF-9D5E-6A040FA7E20C@mac.com> (Shark Fin Soup's message of "Sat, 10 Sep 2005 22:54:43 +0700") References: <8E5DD611-D09B-45AF-9D5E-6A040FA7E20C@mac.com> Message-ID: On Sat, 10 Sep 2005 22:54:43 +0700, Shark Fin Soup wrote: > With the following make file, I am receiving the following error > when trying to run the test. The glue code created with this > makefile has no problem running on SBCL. I am not sure what must be > done to get this working on Lispworks? > > Makefile: > > cl-gd-glue.so: > gcc -I/usr/local/include -I/sw/include -g -c -dynamiclib -o > cl-gd-glue.o cl-gd-gl > ue.c > libtool -dynamic -lgd -lz -lpng -ljpeg -lfreetype -liconv - > lm -lc -o cl-gd-glue.s > o cl-gd-glue.o -L/usr/local/lib -L/sw/lib > rm cl-gd-glue.o > > Lispworks Error: > Error: Foreign function GD-IMAGE-CREATE trying to call to unresolved > external function "gdImageCreate" Hi! I'm sorry but I don't have a Mac to check this and I have no idea what the problem is, especially if this works with SBCL. Can you use other C libraries from LispWorks? Are you using the newest version of LispWorks? I think the best way to proceed is to ask on the LispWorks mailing list. Cheers, Edi. From luismbo at gmail.com Sun Sep 25 23:37:04 2005 From: luismbo at gmail.com (Luis Oliveira) Date: Mon, 26 Sep 2005 00:37:04 +0100 Subject: [cl-gd-devel] CLISP support for CL-GD through CFFI Message-ID: Hello, >From the mailing list archives I see that, earlier this year, Edi didn't wan't to integrate the Carlos Ungil's port to CLISP's FFI: Edi Weitz writes: > Thanks. I've made a new release which fixes the bugs you found and > adds a link to your CLISP port. I'm hesitant to add the port to the > CL-GD distribution itself because it adds a large amount of code that > I can't and won't maintain. I'd rather wait until CLISP is supported > by UFFI... :) Today I saw the thread on comp.lang.lisp from someone trying to use CLISP with CL-GD, looked at one of my todo items for CFFI ("test uffi-compat more") and decided to try CLISP/CL-GD/uffi-compat. Here's a patch: diff -u cl-gd-0.4.8.orig/cl-gd-test.lisp cl-gd-0.4.8.new/cl-gd-test.lisp --- cl-gd-0.4.8.orig/cl-gd-test.lisp Sun Sep 25 23:42:54 2005 +++ cl-gd-0.4.8.new/cl-gd-test.lisp Mon Sep 26 00:06:07 2005 @@ -39,8 +39,8 @@ (defparameter *test-directory* (merge-pathnames (make-pathname :directory '(:relative "test")) (make-pathname :name nil - :type :unspecific - :version :unspecific + :type nil + :version :newest :defaults cl-gd.system:*cl-gd-directory*)) "Where test files are put.") diff -u cl-gd-0.4.8.orig/cl-gd.asd cl-gd-0.4.8.new/cl-gd.asd --- cl-gd-0.4.8.orig/cl-gd.asd Sun Sep 25 23:42:54 2005 +++ cl-gd-0.4.8.new/cl-gd.asd Mon Sep 26 00:06:52 2005 @@ -53,4 +53,4 @@ (:file "drawing" :depends-on ("transform" "colors-aux")) (:file "strings" :depends-on ("transform" "colors-aux")) (:file "misc" :depends-on ("transform"))) - :depends-on (:uffi)) + :depends-on (#-clisp :uffi #+clisp :cffi-uffi-compat)) Common subdirectories: cl-gd-0.4.8.orig/doc and cl-gd-0.4.8.new/doc diff -u cl-gd-0.4.8.orig/specials.lisp cl-gd-0.4.8.new/specials.lisp --- cl-gd-0.4.8.orig/specials.lisp Sun Sep 25 23:42:54 2005 +++ cl-gd-0.4.8.new/specials.lisp Mon Sep 26 00:15:59 2005 @@ -121,16 +121,16 @@ (defconstant +gd-cmp-true-color+ 256 "One image is a true-color image, the other one is palette-based.") -(defvar *shared-library-directories* `(,(namestring (make-pathname :device :unspecific - :name nil - :type :unspecific - :version :unspecific - :defaults cl-gd.system:*cl-gd-directory*)) - "/usr/local/lib/" - "/usr/lib/" - "/usr/lib/cl-gd/" - "/cygwin/usr/local/lib/" - "/cygwin/usr/lib/") +(defvar *shared-library-directories* + `(,(namestring (make-pathname :name nil + :type nil + :version :newest + :defaults cl-gd.system:*cl-gd-directory*)) + "/usr/local/lib/" + "/usr/lib/" + "/usr/lib/cl-gd/" + "/cygwin/usr/local/lib/" + "/cygwin/usr/lib/") "A list of directories where UFFI tries to find cl-gd-glue.so") (defvar *shared-library-types* '("so" "dll") "The list of types a shared library can have. Used when looking for Common subdirectories: cl-gd-0.4.8.orig/test and cl-gd-0.4.8.new/test I tested with the latest CFFI, CLISP 2.35 and CL-GD 0.4.8 under Windows 2000 and it fails 3 or 4 tests. I see Carlos's CLISP port includes some changes to some CL-GD functions other than the FFI part so I assume those changes should be integrated too, but I guess he would know better regarding what needs fixing for proper CLISP support. The pathname changes might break other lisps, I haven't tested, sorry. I hope this helps integrate CLISP support into CL-GD. -- Luis Oliveira luismbo (@) gmail (.) com Equipa Portuguesa do Translation Project http://www.iro.umontreal.ca/translation/registry.cgi?team=pt From edi at agharta.de Mon Sep 26 12:56:55 2005 From: edi at agharta.de (Edi Weitz) Date: Mon, 26 Sep 2005 14:56:55 +0200 Subject: [cl-gd-devel] New version 0.5.0 (Was: CLISP support for CL-GD through CFFI) In-Reply-To: (Luis Oliveira's message of "Mon, 26 Sep 2005 00:37:04 +0100") References: Message-ID: Hi Luis! Thanks for the patch. I've released a new version incorporating your changes and I could successfully use it with CLISP on Linux and Win32 (but /not/ on Cygwin). The pathname changes don't seem to break anything for LispWorks, AllegroCL, or CMUCL. ChangeLog: Version 0.5.0 2005-09-26 Experimental CLISP/CFFI support (thanks to Luis Oliveira) Don't redefine what's already there (for LispWorks) Download: Cheers, Edi. From edi at agharta.de Mon Sep 26 13:56:59 2005 From: edi at agharta.de (Edi Weitz) Date: Mon, 26 Sep 2005 15:56:59 +0200 Subject: [cl-gd-devel] Re: New version 0.5.0 In-Reply-To: (Luis Oliveira's message of "Mon, 26 Sep 2005 14:28:48 +0100") References: Message-ID: On Mon, 26 Sep 2005 14:28:48 +0100, Luis Oliveira wrote: > CFFI's CLISP port is expected to *not* work out of the box on unix > systems as mentioned in CFFI's webpage (it requires a one-line > patch). A one-line patch to CFFI or to CLISP? > Thus, I wouldn't expect it to work on Cygwin. (Actually, I wouldn't > expect it to work out of the box on Linux either, what version of > CLISP are you using there?) See below for versions. Actually, it kind of worked on Cygwin as well - I just had to remove the .FAS files that I created with the native Win32 version. Cheers, Edi. edi at vmware:/tmp$ apt-show-versions -a -p clisp clisp 1:2.35-2 install ok installed clisp 1:2.33.2-10 stable clisp 1:2.33.2-10 testing clisp 1:2.35-2 unstable clisp/unstable uptodate 1:2.35-2 edi at vmware:/tmp$ clisp i i i i i i i ooooo o ooooooo ooooo ooooo I I I I I I I 8 8 8 8 8 o 8 8 I \ `+' / I 8 8 8 8 8 8 \ `-+-' / 8 8 8 ooooo 8oooo `-__|__-' 8 8 8 8 8 | 8 o 8 8 o 8 8 ------+------ ooooo 8oooooo ooo8ooo ooooo 8 Copyright (c) Bruno Haible, Michael Stoll 1992, 1993 Copyright (c) Bruno Haible, Marcus Daniels 1994-1997 Copyright (c) Bruno Haible, Pierpaolo Bernardi, Sam Steingold 1998 Copyright (c) Bruno Haible, Sam Steingold 1999-2000 Copyright (c) Sam Steingold, Bruno Haible 2001-2005 ;; Loading file /home/edi/.clisprc.lisp ... ;; Loaded file /home/edi/.clisprc.lisp [1]> (lisp-implementation-version) "() (built 3335623208) (memory 3336726251)" [2]> (asdf:oos 'asdf:load-op :cl-gd-test) ; loading system definition from /usr/local/lisp/Registry/cl-gd-test.asd into # ;; Loading file /usr/local/lisp/Registry/cl-gd-test.asd ... ; registering # as CL-GD-TEST ;; Loaded file /usr/local/lisp/Registry/cl-gd-test.asd ; loading system definition from /usr/local/lisp/Registry/cl-gd.asd into # ;; Loading file /usr/local/lisp/Registry/cl-gd.asd ... ; registering # as CL-GD ;; Loaded file /usr/local/lisp/Registry/cl-gd.asd ; loading system definition from /usr/local/lisp/Registry/cffi-uffi-compat.asd into # ;; Loading file /usr/local/lisp/Registry/cffi-uffi-compat.asd ... ; registering # as CFFI-UFFI-COMPAT ;; Loaded file /usr/local/lisp/Registry/cffi-uffi-compat.asd ; loading system definition from /usr/local/lisp/Registry/cffi.asd into # ;; Loading file /usr/local/lisp/Registry/cffi.asd ... ; registering # as CFFI ;; Loaded file /usr/local/lisp/Registry/cffi.asd ;; Loading file /usr/local/lisp/source/cffi-luis-050925-2059/src/utils.fas ... ;; Loaded file /usr/local/lisp/source/cffi-luis-050925-2059/src/utils.fas ;; Loading file /usr/local/lisp/source/cffi-luis-050925-2059/src/cffi-clisp.fas ... ;; Loaded file /usr/local/lisp/source/cffi-luis-050925-2059/src/cffi-clisp.fas ;; Loading file /usr/local/lisp/source/cffi-luis-050925-2059/src/package.fas ... ;; Loaded file /usr/local/lisp/source/cffi-luis-050925-2059/src/package.fas ;; Loading file /usr/local/lisp/source/cffi-luis-050925-2059/src/libraries.fas ... ;; Loaded file /usr/local/lisp/source/cffi-luis-050925-2059/src/libraries.fas ;; Loading file /usr/local/lisp/source/cffi-luis-050925-2059/src/early-types.fas ... ;; Loaded file /usr/local/lisp/source/cffi-luis-050925-2059/src/early-types.fas ;; Loading file /usr/local/lisp/source/cffi-luis-050925-2059/src/types.fas ... ;; Loaded file /usr/local/lisp/source/cffi-luis-050925-2059/src/types.fas ;; Loading file /usr/local/lisp/source/cffi-luis-050925-2059/src/enum.fas ... ;; Loaded file /usr/local/lisp/source/cffi-luis-050925-2059/src/enum.fas ;; Loading file /usr/local/lisp/source/cffi-luis-050925-2059/src/strings.fas ... ;; Loaded file /usr/local/lisp/source/cffi-luis-050925-2059/src/strings.fas ;; Loading file /usr/local/lisp/source/cffi-luis-050925-2059/src/functions.fas ... ;; Loaded file /usr/local/lisp/source/cffi-luis-050925-2059/src/functions.fas ;; Loading file /usr/local/lisp/source/cffi-luis-050925-2059/src/foreign-vars.fas ... ;; Loaded file /usr/local/lisp/source/cffi-luis-050925-2059/src/foreign-vars.fas ;; Loading file /usr/local/lisp/source/cffi-luis-050925-2059/src/objects.fas ... ;; Loaded file /usr/local/lisp/source/cffi-luis-050925-2059/src/objects.fas ;; Loading file /usr/local/lisp/source/cffi-luis-050925-2059/uffi-compat/uffi-compat.fas ... ;; Loaded file /usr/local/lisp/source/cffi-luis-050925-2059/uffi-compat/uffi-compat.fas ;; Loading file /usr/local/lisp/source/cl-gd/packages.fas ... ;; Loaded file /usr/local/lisp/source/cl-gd/packages.fas ;; Compiling file /usr/local/lisp/source/cl-gd/util.lisp ... ;; Wrote file /usr/local/lisp/source/cl-gd/util.fas ;; Loading file /usr/local/lisp/source/cl-gd/util.fas ... ;; Loaded file /usr/local/lisp/source/cl-gd/util.fas ;; Compiling file /usr/local/lisp/source/cl-gd/specials.lisp ... ;; Wrote file /usr/local/lisp/source/cl-gd/specials.fas ;; Loading file /usr/local/lisp/source/cl-gd/specials.fas ... ;; Loaded file /usr/local/lisp/source/cl-gd/specials.fas ;; Compiling file /usr/local/lisp/source/cl-gd/init.lisp ... ;; Wrote file /usr/local/lisp/source/cl-gd/init.fas ;; Loading file /usr/local/lisp/source/cl-gd/init.fas ... #P"/usr/local/lisp/source/cl-gd/cl-gd-glue.so" ;; Loaded file /usr/local/lisp/source/cl-gd/init.fas ;; Compiling file /usr/local/lisp/source/cl-gd/gd-uffi.lisp ... ;; Wrote file /usr/local/lisp/source/cl-gd/gd-uffi.fas ;; Loading file /usr/local/lisp/source/cl-gd/gd-uffi.fas ... ;; Loaded file /usr/local/lisp/source/cl-gd/gd-uffi.fas ;; Compiling file /usr/local/lisp/source/cl-gd/transform.lisp ... ;; Wrote file /usr/local/lisp/source/cl-gd/transform.fas ;; Loading file /usr/local/lisp/source/cl-gd/transform.fas ... ;; Loaded file /usr/local/lisp/source/cl-gd/transform.fas ;; Compiling file /usr/local/lisp/source/cl-gd/images.lisp ... ;; Wrote file /usr/local/lisp/source/cl-gd/images.fas ;; Compiling file /usr/local/lisp/source/cl-gd/colors-aux.lisp ... ;; Wrote file /usr/local/lisp/source/cl-gd/colors-aux.fas ;; Compiling file /usr/local/lisp/source/cl-gd/colors.lisp ... ;; Wrote file /usr/local/lisp/source/cl-gd/colors.fas ;; Loading file /usr/local/lisp/source/cl-gd/colors-aux.fas ... ;; Loaded file /usr/local/lisp/source/cl-gd/colors-aux.fas ;; Compiling file /usr/local/lisp/source/cl-gd/drawing.lisp ... ;; Wrote file /usr/local/lisp/source/cl-gd/drawing.fas ;; Compiling file /usr/local/lisp/source/cl-gd/strings.lisp ... ;; Wrote file /usr/local/lisp/source/cl-gd/strings.fas ;; Compiling file /usr/local/lisp/source/cl-gd/misc.lisp ... ;; Wrote file /usr/local/lisp/source/cl-gd/misc.fas ;; Loading file /usr/local/lisp/source/cl-gd/images.fas ... ;; Loaded file /usr/local/lisp/source/cl-gd/images.fas ;; Loading file /usr/local/lisp/source/cl-gd/colors.fas ... ;; Loaded file /usr/local/lisp/source/cl-gd/colors.fas ;; Loading file /usr/local/lisp/source/cl-gd/drawing.fas ... ;; Loaded file /usr/local/lisp/source/cl-gd/drawing.fas ;; Loading file /usr/local/lisp/source/cl-gd/strings.fas ... ;; Loaded file /usr/local/lisp/source/cl-gd/strings.fas ;; Loading file /usr/local/lisp/source/cl-gd/misc.fas ... ;; Loaded file /usr/local/lisp/source/cl-gd/misc.fas ;; Compiling file /usr/local/lisp/source/cl-gd/cl-gd-test.lisp ... ;; Wrote file /usr/local/lisp/source/cl-gd/cl-gd-test.fas ;; Loading file /usr/local/lisp/source/cl-gd/cl-gd-test.fas ... ;; Loaded file /usr/local/lisp/source/cl-gd/cl-gd-test.fas 0 errors, 0 warnings NIL [3]> (cl-gd-test:test) Test 1 succeeded. Test 2 succeeded. Test 3 succeeded. Test 4 succeeded. Test 5 succeeded. Test 6 succeeded. Test 7 succeeded. Test 8 succeeded. Test 9 succeeded. Test 10 succeeded. Test 11 failed with the following error: =: NIL is not a number Test 12 failed with the following error: FFI:FOREIGN-VARIABLE: NIL is not of type (OR FFI:FOREIGN-VARIABLE FFI:FOREIGN-ADDRESS) Test 13 succeeded. Test 14 succeeded. Test 15 succeeded. Test 16 failed with the following error: FFI:FOREIGN-VARIABLE: NIL is not of type (OR FFI:FOREIGN-VARIABLE FFI:FOREIGN-ADDRESS) Test 17 failed. Test 18 succeeded. Test 19 failed with the following error: FFI:FOREIGN-VARIABLE: NIL is not of type (OR FFI:FOREIGN-VARIABLE FFI:FOREIGN-ADDRESS) Done. NIL From luismbo at gmail.com Mon Sep 26 14:39:22 2005 From: luismbo at gmail.com (Luis Oliveira) Date: Mon, 26 Sep 2005 15:39:22 +0100 Subject: [cl-gd-devel] Re: New version 0.5.0 References: Message-ID: Edi Weitz writes: > On Mon, 26 Sep 2005 14:28:48 +0100, Luis Oliveira wrote: > >> CFFI's CLISP port is expected to *not* work out of the box on unix >> systems as mentioned in CFFI's webpage (it requires a one-line >> patch). > > A one-line patch to CFFI or to CLISP? CLISP, but this has apparently been fixed in version 2.35, which is good news. So, nevermind what I said before, this will work on all platforms. CL-GD specific problems with CLISP remain though, as shown by those test failures. (Eventually some /might/ be uffi-compat bugs.) -- Luis Oliveira luismbo (@) gmail (.) com Equipa Portuguesa do Translation Project http://www.iro.umontreal.ca/translation/registry.cgi?team=pt From edi at agharta.de Mon Sep 26 14:59:12 2005 From: edi at agharta.de (Edi Weitz) Date: Mon, 26 Sep 2005 16:59:12 +0200 Subject: [cl-gd-devel] Re: New version 0.5.0 In-Reply-To: (Luis Oliveira's message of "Mon, 26 Sep 2005 15:39:22 +0100") References: Message-ID: On Mon, 26 Sep 2005 15:39:22 +0100, Luis Oliveira wrote: > CLISP, but this has apparently been fixed in version 2.35, which is > good news. So, nevermind what I said before, this will work on all > platforms. Good. > CL-GD specific problems with CLISP remain though, as shown by those > test failures. (Eventually some /might/ be uffi-compat bugs.) Unfortunately, I don't have enough time to track these down and I'm not a regular CLISP user. If someone sends patches to make CLISP work with CL-GD I'll be happy to integrate them. Thanks again, Edi.