From pvaneynde at common-lisp.net Wed Jan 25 19:25:46 2006 From: pvaneynde at common-lisp.net (pvaneynde) Date: Wed, 25 Jan 2006 13:25:46 -0600 (CST) Subject: [pg-cvs] CVS pg Message-ID: <20060125192546.EBE351D436@common-lisp.net> Update of /project/pg/cvsroot/pg In directory common-lisp:/tmp/cvs-serv24995 Modified Files: pg.lisp Log Message: fix typo in pg-close-portal documentation --- /project/pg/cvsroot/pg/pg.lisp 2005/07/17 15:48:06 1.5 +++ /project/pg/cvsroot/pg/pg.lisp 2006/01/25 19:25:46 1.6 @@ -204,7 +204,7 @@ (defgeneric pg-close-portal (connection portal) (:documentation - "Closes a prepared statement")) + "Closes a prepared statement portal")) (defgeneric pglo-read (connection fd bytes) (:documentation From emarsden at common-lisp.net Fri Jan 27 17:51:53 2006 From: emarsden at common-lisp.net (emarsden) Date: Fri, 27 Jan 2006 11:51:53 -0600 (CST) Subject: [pg-cvs] CVS pg Message-ID: <20060127175153.384578006@common-lisp.net> Update of /project/pg/cvsroot/pg In directory common-lisp:/tmp/cvs-serv14288 Modified Files: md5.lisp pg.asd Log Message: Load sb-rotate-byte from the ASD file. --- /project/pg/cvsroot/pg/md5.lisp 2005/07/17 15:44:48 1.2 +++ /project/pg/cvsroot/pg/md5.lisp 2006/01/27 17:51:53 1.3 @@ -9,7 +9,7 @@ ;;;; SB-MD5 contrib, with minor changes to compile in other Common ;;;; Lisp implementations. ;;;; -;;;; $Id: md5.lisp,v 1.2 2005/07/17 15:44:48 emarsden Exp $ +;;;; $Id: md5.lisp,v 1.3 2006/01/27 17:51:53 emarsden Exp $ ;;;; ;;;; While the implementation should work on all conforming Common ;;;; Lisp implementations, it has only been optimized for CMU CL, @@ -48,10 +48,6 @@ (in-package :PG-MD5) -#+sbcl -(eval-when (:load-toplevel :compile-toplevel) - (require :sb-rotate-byte)) - #+cmu (eval-when (:compile-toplevel) (defparameter *old-expansion-limit* ext:*inline-expansion-limit*) --- /project/pg/cvsroot/pg/pg.asd 2005/10/18 13:07:27 1.8 +++ /project/pg/cvsroot/pg/pg.asd 2006/01/27 17:51:53 1.9 @@ -21,6 +21,7 @@ #+lispworks "comm" #+cormanlisp :sockets #+sbcl :sb-bsd-sockets + #+sbcl :sb-rotate-byte #+(and mcl (not openmcl)) "OPENTRANSPORT") :components ((:file "md5") (:file "defpackage" :depends-on ("md5")) From emarsden at common-lisp.net Fri Jan 27 18:03:39 2006 From: emarsden at common-lisp.net (emarsden) Date: Fri, 27 Jan 2006 12:03:39 -0600 (CST) Subject: [pg-cvs] CVS pg Message-ID: <20060127180339.B2E2FB6AC@common-lisp.net> Update of /project/pg/cvsroot/pg In directory common-lisp:/tmp/cvs-serv16285 Modified Files: sysdep.lisp Log Message: Fix for encoding support for CLISP and OpenMCL (encoding still not working correctly). OpenMCL fix from Risto Laakso. --- /project/pg/cvsroot/pg/sysdep.lisp 2005/12/19 22:21:50 1.12 +++ /project/pg/cvsroot/pg/sysdep.lisp 2006/01/27 18:03:39 1.13 @@ -1,7 +1,7 @@ ;;; sysdep.lisp -- system-dependent parts of pg-dot-lisp ;;; ;;; Author: Eric Marsden -;;; Time-stamp: <2005-12-09 emarsden> +;;; Time-stamp: <2006-01-27 emarsden> ;; ;; @@ -327,27 +327,25 @@ (defun implementation-name-for-encoding (encoding) (%sysdep "client encoding to external format name" #+(and clisp unicode) - (cond ((string= encoding "SQL_ASCII") :ascii) - ((string= encoding "LATIN1") :latin1) - ((string= encoding "LATIN9") :latin9) - ((string= encoding "UNICODE") :utf8) + (cond ((string= encoding "SQL_ASCII") charset:ascii) + ((string= encoding "LATIN1") charset:iso-8859-1) + ((string= encoding "LATIN9") charset:iso-8859-9) + ((string= encoding "UTF8") charset:utf-8) (t (error "unknown encoding ~A" encoding))) #+(and allegro ics) (cond ((string= encoding "SQL_ASCII") :ascii) ((string= encoding "LATIN1") :latin1) ((string= encoding "LATIN9") :latin9) - ((string= encoding "UNICODE") :utf8) + ((string= encoding "UTF8") :utf8) (t (error "unknown encoding ~A" encoding))) #+(and sbcl sb-unicode) (cond ((string= encoding "SQL_ASCII") :ascii) ((string= encoding "LATIN1") :latin1) ((string= encoding "LATIN9") :latin9) - ((string= encoding "UNICODE") :utf8) + ((string= encoding "UTF8") :utf8) (t (error "unknown encoding ~A" encoding))) - #+(or cmu gcl ecl abcl) - (cond ((string= encoding "SQL_ASCII") :ascii) - ((string= encoding "LATIN1") :latin1) - ((string= encoding "LATIN9") :latin9)))) + #+(or cmu gcl ecl abcl openmcl) + nil)) (defun convert-string-to-bytes (string &optional (encoding *pg-client-encoding*)) (declare (type string string)) @@ -360,7 +358,7 @@ #+(and :sbcl :sb-unicode) (sb-ext:string-to-octets string :external-format (implementation-name-for-encoding encoding)) - #+(or cmu gcl ecl abcl) + #+(or cmu gcl ecl abcl openmcl) (if (member encoding '("SQL_ASCII" "LATIN1" "LATIN9") :test #'string-equal) (let ((octets (make-array (length string) :element-type '(unsigned-byte 8)))) (map-into octets #'char-code string)) @@ -378,7 +376,7 @@ ;; for implementations that have no support for character ;; encoding, we assume that the encoding is an octet-for-octet ;; encoding, and convert directly - #+(or cmu (and sbcl (not :sb-unicode)) gcl ecl abcl) + #+(or cmu (and sbcl (not :sb-unicode)) gcl ecl abcl openmcl) (let ((string (make-string (length bytes)))) (map-into string #'code-char bytes))))