use md5sum-string instead of md5sum-sequence to adjust to upstream changes
[clsql.git] / db-odbc / odbc-loader.lisp
1 ;;;; -*- Mode: LISP; Syntax: ANSI-Common-Lisp; Base: 10 -*-
2 ;;;; *************************************************************************
3 ;;;; FILE IDENTIFICATION
4 ;;;;
5 ;;;; Name:          odbc-loader.sql
6 ;;;; Purpose:       ODBC library loader using UFFI
7 ;;;; Programmers:   Kevin M. Rosenberg
8 ;;;; Date Started:  April 2004
9 ;;;;
10 ;;;; This file, part of CLSQL, is Copyright (c) 2004 by Kevin M. Rosenberg
11 ;;;;
12 ;;;; CLSQL users are granted the rights to distribute and use this software
13 ;;;; as governed by the terms of the Lisp Lesser GNU Public License
14 ;;;; (http://opensource.franz.com/preamble.html), also known as the LLGPL.
15 ;;;; *************************************************************************
16
17 (in-package #:odbc)
18
19 (defparameter *odbc-library-filenames*
20   '("odbc32" "libodbc" "libiodbc"))
21
22 (defvar *odbc-supporting-libraries* '("c")
23   "Used only by CMU. List of library flags needed to be passed to ld to
24 load the Odbc client library succesfully.  If this differs at your site,
25 set to the right path before compiling or loading the system.")
26
27 (defvar *odbc-library-loaded* nil
28   "T if foreign library was able to be loaded successfully")
29
30 (defmethod clsql-sys:database-type-library-loaded ((database-type (eql :odbc)))
31   *odbc-library-loaded*)
32
33 (defmethod clsql-sys:database-type-load-foreign ((database-type (eql :odbc)))
34   (clsql-uffi:find-and-load-foreign-library *odbc-library-filenames*
35                                             :module "odbc")
36   (setq *odbc-library-loaded* t))
37
38 (clsql-sys:database-type-load-foreign :odbc)
39
40
41