X-Git-Url: http://git.kpe.io/?a=blobdiff_plain;ds=sidebyside;f=interfaces%2Fpostgresql%2Fpostgresql-loader.cl;h=a2b7988c7bb1513f02850a933c7689bf0b314210;hb=9a78eef71c902d3b272fb7c777bff6dd0acd8a2b;hp=4db5fd426a63054a5e2b6f77075a191380d2fb3c;hpb=b06cb6d32e2a334f7dc72e8fb583a5b9609136b7;p=clsql.git diff --git a/interfaces/postgresql/postgresql-loader.cl b/interfaces/postgresql/postgresql-loader.cl index 4db5fd4..a2b7988 100644 --- a/interfaces/postgresql/postgresql-loader.cl +++ b/interfaces/postgresql/postgresql-loader.cl @@ -7,7 +7,7 @@ ;;;; Programmer: Kevin M. Rosenberg ;;;; Date Started: Feb 2002 ;;;; -;;;; $Id: postgresql-loader.cl,v 1.1 2002/03/23 14:04:53 kevin Exp $ +;;;; $Id: postgresql-loader.cl,v 1.2 2002/03/24 04:01:26 kevin Exp $ ;;;; ;;;; This file, part of CLSQL, is Copyright (c) 2002 by Kevin M. Rosenberg ;;;; @@ -39,10 +39,18 @@ load the PostgresSQL client library succesfully. If this differs at your site, set to the right path before compiling or loading the system.") +(defvar *postgresql-library-loaded* nil + "T if foreign library was able to be loaded successfully") + +(defmethod database-type-library-loaded ((database-type (eql :postgresql))) + *postgresql-library-loaded*) + (defmethod database-type-load-foreign ((database-type (eql :postgresql))) - (uffi:load-foreign-library *postgresql-library-filename* - :module "postgresql" - :supporting-libraries - *postgresql-supporting-libraries*)) + (when + (uffi:load-foreign-library *postgresql-library-filename* + :module "postgresql" + :supporting-libraries + *postgresql-supporting-libraries*) + (setq *postgresql-library-loaded* t))) (database-type-load-foreign :postgresql)